DEFSTRUCT should signal error/warning if :PREDICATE + :TYPE without :NAMED
Bug #520607 reported by
Tobias C. Rittweiler
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SBCL |
Fix Released
|
Low
|
Unassigned |
Bug Description
CLHS says
A predicate can be defined only if the structure is named;
if :type is supplied and :named is not supplied, then
:predicate must either be unsupplied or have the value nil.
Yet SBCL compiles
(defstruct (typed-struct (:type list) (:predicate typed-struct-p))
(a 42 :type fixnum))
silently, and it seems to ignore the :PREDICATE clause.
Changed in sbcl: | |
status: | New → Confirmed |
importance: | Undecided → Low |
Changed in sbcl: | |
assignee: | nobody → Nikodemus Siivola (nikodemus) |
status: | Confirmed → In Progress |
Changed in sbcl: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
The patch for this problem, with the regression test.