compilator: fixes issue #3 (regression on package :lapack).

cmptype-arith.lsp: problem introduced in commit
c0b23555c6 which added empty &optional
clause and &allow-other-keys capability to typespec for values.

Problem was, that multiple &optional keywords in typespec it
considered error, while

'(VALUES &OPTIONAL T &OPTIONAL T)

should return as optional part, list (T &optional T) - even if it
looks weird.
This commit is contained in:
Daniel Kochmański 2015-03-05 23:45:22 +01:00
parent 63a0d656d9
commit 7229cfefc9

View file

@ -176,9 +176,9 @@
(when l
(cmperr "Syntax error in type expression ~S" type)))
(&optional
(when optional-flag
(cmperr "Syntax error in type expression ~S" type))
(setf optional-flag t))
(if optional-flag
(push typespec optional)
(setf optional-flag t)))
(&rest
(when (or (null l)
(not (member (rest l) '(() (&allow-other-keys))