Next: 4.4.5 Errors During Macroexpansion
Up: 4.4 Interpreting Error Messages
Previous: 4.4.3 The Processing Path
There are three levels of compiler error severity:
- Error
- This severity is used when the compiler encounters a
problem serious enough to prevent normal processing of a form.
Instead of compiling the form, the compiler compiles a call to
error. Errors are used mainly for signalling syntax errors.
If an error happens during macroexpansion, the compiler will handle
it. The compiler also handles and attempts to proceed from read
errors.
- Warning
- Warnings are used when the compiler can prove that
something bad will happen if a portion of the program is executed,
but the compiler can proceed by compiling code that signals an error
at runtime if the problem has not been fixed:
- Violation of type declarations, or
- Function calls that have the wrong number of arguments or
malformed keyword argument lists, or
- Referencing a variable declared ignore, or unrecognized
declaration specifiers.
In the language of the Common Lisp standard, these are situations where
the compiler can determine that a situation with undefined
consequences or that would cause an error to be signalled would
result at runtime.
- Note
- Notes are used when there is something that seems a bit
odd, but that might reasonably appear in correct programs.
Note that the compiler does not fully conform to the proposed X3J13
``compiler-diagnostics'' cleanup. Errors, warnings and notes mostly
correspond to errors, warnings and style-warnings, but many things
that the cleanup considers to be style-warnings are printed as
warnings rather than notes. Also, warnings, style-warnings and most
errors aren't really signalled using the condition system.
Raymond Toy
Mon Jul 14 09:11:27 EDT 1997