(COND ()) error message tweaking

Bug #1254511 reported by Pascal J. Bourguignon
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SBCL
Fix Released
Undecided
Unassigned

Bug Description

On (COND ()) SBCL reports: COND clause is not a list: NIL
this is not correct, nil IS a list.
The error message should be: COND clause is invalid, it should be an non-empty list.

Tested on sbcl 1.1.1.0.debian

Revision history for this message
Erik Krisztián Varga (erik-varga256) wrote :

Added a patch. This displays a different message when clause is NIL.

Revision history for this message
Stas Boukarev (stassats) wrote :

Myabe instead of checking for NIL just say that it is not a CONS? And for the patch to get applied directly you need to:
a) mention the ticket in the commit message
b) add a description to the NEWS file, mentioning the ticket number.
See other commits for examples.

Revision history for this message
Christophe Rhodes (csr21-cantab) wrote : Re: [Bug 1254511] Re: (COND ()) error message tweaking

Stas Boukarev <email address hidden> writes:

> Myabe instead of checking for NIL just say that it is not a CONS? And
> for the patch to get applied directly you need to:
> a) mention the ticket in the commit message
> b) add a description to the NEWS file, mentioning the ticket number.
> See other commits for examples.

For extra style points, you could use a simple-type-error to indicate
the expected type of the datum.

Christophe

Revision history for this message
Erik Krisztián Varga (erik-varga256) wrote :

Yeah, I guess that makes more sense than handling NIL separately. Here's an updated patch, with the ticket number added.
For this to get applied, should I push it into the repo myself?

Revision history for this message
Stas Boukarev (stassats) wrote :

Applied in caa5c21b29bbe633dbc72f23677412213080f314, thanks. And git format-patch is the best way to provide patches. And you copied a typo from a commit message, it should be lp#1254511, not lp1254511.

Changed in sbcl:
status: New → Fix Committed
Revision history for this message
Erik Krisztián Varga (erik-varga256) wrote :

All right, thanks. Sorry about the typo, I checked another commit to see what to write and thought that was the required format.

Changed in sbcl:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.