1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-18 10:10:23 +02:00
guile/module/language
Brian Templeton 7d6816f0c7 store special operators in the function slot
If the function slot of a symbol contains a pair with `special-operator'
in the car and a procedure in the cdr, the procedure is called to
compile the form to Tree-IL. This is similar to other Emacs Lisp
implementations, in which special operators are subrs.

* module/language/elisp/compile-tree-il.scm: Restructured to store
  special operator definitions in the function slot. Import `(language
  elisp runtime)' for `defspecial'. Export special operators so that
  `(language elisp runtime function-slot)' can re-export them.

  (backquote?): Removed; the backquote symbol is defined as a special
  operator, so it's no longer used in `compile-pair'.

  (is-macro?, get-macro): Replaced by `find-operator'.
  (find-operator): New procedure.

  (compile-progn, compile-if, compile-defconst, compile-defvar,
  compile-setq, compile-let, compile-lexical-let, compile-flet,
  compile-let*, compile-lexical-let*, compile-flet*,
  compile-without-void-checks, compile-with-always-lexical,
  compile-guile-ref, compile-guile-primitive, compile-while,
  compile-function, compile-defmacro, compile-defun, #{compile-`}#,
  compile-quote): New special operators with definitions taken from the
  pmatch form in `compile-pair'. There is no special operator `lambda';
  it is now a macro, as in other Elisp implementations.

  (compile-pair): Instead of directly compiling special forms, check for
  a special operator object in the function slot.

* module/language/elisp/runtime.scm: Export `defspecial'.
  (make-id): New function.
  (built-in-macro): Prefix macros with `macro-'.
  (defspecial): New syntax.

* module/language/elisp/runtime/function-slot.scm: Import and re-export
  special operators. Rename imported special operators and macros to
  remove prefixes. Re-export new macro `lambda'.

* module/language/elisp/runtime/macros.scm (macro-lambda): New Elisp
  macro.
2010-08-13 16:35:51 -04:00
..
assembly rename (rnrs bytevector) to (rnrs bytevectors) 2010-06-01 13:26:11 +02:00
brainfuck remove `version' field from <language> 2010-05-02 11:19:13 +02:00
bytecode remove `version' field from <language> 2010-05-02 11:19:13 +02:00
ecmascript remove `version' field from <language> 2010-05-02 11:19:13 +02:00
elisp store special operators in the function slot 2010-08-13 16:35:51 -04:00
glil rename (rnrs bytevector) to (rnrs bytevectors) 2010-06-01 13:26:11 +02:00
objcode Add program-free-variables' to (system vm program)'. 2010-05-07 13:47:52 +02:00
scheme fix a comment about environments and the scheme compiler 2010-05-02 11:19:46 +02:00
tree-il resolve-primitives tweaks 2010-06-17 13:43:26 +02:00
value remove `version' field from <language> 2010-05-02 11:19:13 +02:00
assembly.scm rename (rnrs bytevector) to (rnrs bytevectors) 2010-06-01 13:26:11 +02:00
glil.scm prompt handlers are always inline 2010-02-19 15:30:34 +01:00
objcode.scm Change Guile license to LGPLv3+ 2009-06-17 00:22:09 +01:00
tree-il.scm Remove trailing whitespace 2010-07-09 21:22:27 -05:00