![]() | ![]() | ![]() | defcm | ![]() |
| name | [Macro] |
Purpose
Define a read-time conditional compiler macro.
Package :gbbopen-tools
Module :gbbopen-tools
Arguments and values
name | A non-nil , non-keyword symbol that names a function or macro
| |
lambda-list | A lambda-list | |
declaration | A declare expression (not evaluated) | |
documentation | A documentation string (not evaluated) | |
form | A form |
Returns
The supplied name.
Description
Defcm is a read-time conditional version of Common Lisp's
define-compiler-macro
define-compiler-macro
&whole
argument is bound to the form argument that is passed
to funcall
compiler-macro
&whole
See also
:disable-compiler-macros
:full-safety
Example
Here is the compiler macro defined for
> (defcm ensure-list (x) (with-once-only-bindings (x) `(if (listp ,x) ,x (list ,x)))) ensure-list >
The GBBopen Project
![]() | ![]() | ![]() | defcm | ![]() |