COERCE should signal an error on several character coercions
Bug #841312 reported by
Lutz Euler
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SBCL |
Fix Released
|
Low
|
Unassigned |
Bug Description
In SBCL 1.0.51.29-cd470a0, the expression
(mapcar 'type-of (list
(coerce #\Nak 'standard-char)
(coerce #\a 'extended-char)
(coerce (code-char 955) 'base-char)
(coerce 'a 'standard-char)
(coerce "a" 'standard-char)))
evaluates to
(BASE-CHAR STANDARD-CHAR EXTENDED-CHAR STANDARD-CHAR STANDARD-CHAR)
I had expected it to throw an error instead as IMO all five
coercions are impossible according to CLHS entry COERCE.
I have a patch for this that I will attach as soon as
launchpad tells me the bug number (which I need
to name the test case).
Greetings,
Lutz
Changed in sbcl: | |
assignee: | nobody → Lutz Euler (lutz-euler) |
Changed in sbcl: | |
status: | New → Triaged |
importance: | Undecided → Low |
Changed in sbcl: | |
status: | Triaged → In Progress |
Changed in sbcl: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
I just committed a modified version of the patch from #1 stream. impure. lisp" readable under non-unicode SBCL
(leaving out the part that made the test "BUG-657183" in
"tests/
and skipped it there, as something to that effect has been
committed in the meantime, and adding a NEWS entry).