[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

more on CASEQ

The definition of CASEQ for symbols as you describe is fine. The problem
comes in its being then asymmetric for the fixnum case. You do not want
to allow the fixnum case to expand into 

  (LET ((TEMP form))
    (COND ((= TEMP thing1) ...)
          ((= TEMP thing2) ...)
	  ((OR (= TEMP thing3) (= TEMP thing4)) ...)
	 (T ...)))

since arbitrary forms cannot be compared with = and since one does not
want to waste time doing a typep check in compiled code. hence in the
interpreter, you do want an error for non-fixnum 1st arg... so by symmetry
(if you care about such things), you should get an error for non-symbol
first arg in the symbol case. that at least is what i believe to have been
the reasoning involved in the original decision.