From 06092ed641dc7126064b25c5377cbd953bb7c4c6 Mon Sep 17 00:00:00 2001 From: Christophe Rhodes Date: Mon, 23 Mar 2009 11:59:48 +0000 Subject: [PATCH] 1.0.26.20: tighter VECTOR-PUSH-EXTEND argument type The optional extension parameter must be a positive integer. ... declare this in fndb; ... fix the erroneous use in constraints (not only ensuring positivity, but also it's an extension not a new-length parameter). Issue brought to light by Peter Graves' XCL. --- src/compiler/constraint.lisp | 2 +- src/compiler/fndb.lisp | 3 ++- version.lisp-expr | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/compiler/constraint.lisp b/src/compiler/constraint.lisp index de2beec..e087eaf 100644 --- a/src/compiler/constraint.lisp +++ b/src/compiler/constraint.lisp @@ -357,7 +357,7 @@ (let ((new (make-constraint (length *constraint-universe*) kind x y not-p))) (vector-push-extend new *constraint-universe* - (* 2 (length *constraint-universe*))) + (1+ (length *constraint-universe*))) (conset-adjoin new (lambda-var-constraints x)) (when (lambda-var-p y) (conset-adjoin new (lambda-var-constraints y))) diff --git a/src/compiler/fndb.lisp b/src/compiler/fndb.lisp index a814990..6fb5eb8 100644 --- a/src/compiler/fndb.lisp +++ b/src/compiler/fndb.lisp @@ -871,7 +871,8 @@ (defknown fill-pointer (vector) index (foldable unsafely-flushable)) (defknown vector-push (t vector) (or index null) () :destroyed-constant-args (nth-constant-args 2)) -(defknown vector-push-extend (t vector &optional index) index () +(defknown vector-push-extend (t vector &optional (and index (integer 1))) + index () :destroyed-constant-args (nth-constant-args 2)) (defknown vector-pop (vector) t () :destroyed-constant-args (nth-constant-args 1)) diff --git a/version.lisp-expr b/version.lisp-expr index f401656..352ec8a 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; checkins which aren't released. (And occasionally for internal ;;; versions, especially for internal versions off the main CVS ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".) -"1.0.26.19" +"1.0.26.20" -- 1.7.10.4