mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-07-03 08:10:31 +02:00
only evaluate top-level macro definitions
(Best-ability ChangeLog annotation added by Christopher Allan Webber.) * module/language/elisp/compile-tree-il.scm (defmacro): Check to see whether toplevel? is true before compiling a macro.
This commit is contained in:
parent
4c6ef2b4cb
commit
93b8b53c65
1 changed files with 2 additions and 1 deletions
|
@ -782,7 +782,8 @@
|
||||||
args
|
args
|
||||||
body))))
|
body))))
|
||||||
(make-const loc name))))
|
(make-const loc name))))
|
||||||
(compile tree-il #:from 'tree-il #:to 'value)
|
(when (fluid-ref toplevel?)
|
||||||
|
(compile tree-il #:from 'tree-il #:to 'value))
|
||||||
tree-il)))
|
tree-il)))
|
||||||
(else (report-error loc "bad defmacro" args))))
|
(else (report-error loc "bad defmacro" args))))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue