next up previous contents
Next: 4.4.3 The Processing Path Up: 4.4 Interpreting Error Messages Previous: 4.4.1 The Parts of

4.4.2 The Original and Actual Source

   

The ıoriginal source displayed will almost always be a list. If the actual source for an error message is a symbol, the original source will be the immediately enclosing evaluated list form. So even if the offending symbol does appear in the original source, the compiler will print the enclosing list and then print the symbol as the actual source (as though the symbol were introduced by a macro.)

When the ıactual source is displayed (and is not a symbol), it will always be code that resulted from the expansion of a macro or a source-to-source compiler optimization. This is code that did not appear in the original source program; it was introduced by the compiler.

Keep in mind that when the compiler displays a source form in an error message, it always displays the most specific (innermost) responsible form. For example, compiling this function:

(defun bar (x)
  (let (a)
    (declare (fixnum a))
    (setq a (foo x))
    a))
Gives this error message:
In: DEFUN BAR
  (LET (A) (DECLARE (FIXNUM A)) (SETQ A (FOO X)) A)
Warning: The binding of A is not a FIXNUM:
  NIL
This error message is not saying ``there's a problem somewhere in this let''--it is saying that there is a problem with the let itself. In this example, the problem is that a's nil initial value is not a fixnum.



Raymond Toy
Mon Jul 14 09:11:27 EDT 1997