Add incf!
[jscl.git] / test.lisp
index 36331f2..54d4a63 100644 (file)
--- a/test.lisp
+++ b/test.lisp
   (%compile-defun 'f))
 (fsetq f (lambda (x) (+ x 10)))
 (debug (f 20))
+
+;;; Macros
+(debug "---MACROS---")
+
+(eval-when-compile
+  (%compile-defmacro 'incf
+                     (lambda (y)
+                       (list 'setq y (list '+ 1 y)))))
+
+(eval-when-compile
+  (%compile-defvar 'x))
+
+(setq x 0)
+(incf x)
+(debug x)