Commit [333049] Maximize Restore History

adjust compiler-macro expansion and lambda-list parsing

* Don't convert errors during compiler-macro expansion into runtime
PROGRAM-ERRORs: signal a compile-time warning, and simply decline to expand
the compiler-macro.

This lives in CAREFUL-EXPAND-MACRO.

* Make compiler not expand compiler-macros if there are arguments in keyword
positions that are not self-evaluating constant symbols.

This lives in two places:

(1) VERIFY-KEYWORDS signals a COMPILER-MACRO-KEYWORD-PROBLEM when it
encounters either an unknown keyword or anything except a
self-evaluating symbol in a keyword position when parsing
compiler-macro keywords.

(2) IR1-CONVERT-FUNCTOID handles this condition by unwinding from the
compiler-macro expansion, printing a note about the problem, and
returning the original form.

Calling COMPILER-MACRO-FUNCTION directly behaves exactly as before, for
both good and ill: good in the sense that it is compliant, ill in the
sense that doing things that way may expand things the compiler would
decline to expand:

(define-compiler-macro foo (&key ((a ax) t)) (format nil "a=~S" ax))

The compiler would refuse to expand (foo a 42) unless

(defconstant a 'a)

had been done beforehand, but calling the COMPILER-MACRO-FUNCTION directly
would expand it even without that -- as the spec unfortuntely requires.

Nikodemus Siivola Nikodemus Siivola 2011-12-03

changed src/code/condition.lisp
changed src/code/parse-defmacro.lisp
changed src/compiler/ir1report.lisp
changed src/compiler/ir1tran.lisp
changed tests/compiler.impure.lisp
changed NEWS
changed package-data-list.lisp-expr
src/code/condition.lisp Diff Switch to side-by-side view
Loading...
src/code/parse-defmacro.lisp Diff Switch to side-by-side view
Loading...
src/compiler/ir1report.lisp Diff Switch to side-by-side view
Loading...
src/compiler/ir1tran.lisp Diff Switch to side-by-side view
Loading...
tests/compiler.impure.lisp Diff Switch to side-by-side view
Loading...
NEWS Diff Switch to side-by-side view
Loading...
package-data-list.lisp-expr Diff Switch to side-by-side view
Loading...