Ben Goetter <goetter@angrygraycat.com.xyz> wrote:
+---------------
| You've spoofed the very simple SIOD evaluator. If the SIOD evaluator
| finds a symbol, it will evaluate that symbol, then recur.
|
| > (set! c 'hi)
| > (c) => ERROR: unbound variable (errobj hi)
|
| SIOD's trying to evaluate the symbol you gave it as a procedure. Looks
| up C, gets the symbol Hi; looks up Hi with no joy.
+---------------
Actually, in SIOD this is considered a "feature", not a "bug", ;-} ;-}
and is the macro mechanism in SIOD [transcript edited some]:
> (define (mq-expander form)
(puts "DEBUG: mq-expander: form = ")
(print form)
(cons 'quote (cdr form)))
> (define my-quote 'mq-expander)
mq-expander
> (my-quote 5)
DEBUG: mq-expander: form = (my-quote 5)
5
> (my-quote (this that (the other) thing))
DEBUG: mq-expander: form = (my-quote (this that (the other) thing))
(this that (the other) thing)
>
-Rob
-----
Rob Warnock, 8L-855 rpw3@sgi.com
Applied Networking http://reality.sgi.com/rpw3/
Silicon Graphics, Inc. Phone: 650-933-1673
2011 N. Shoreline Blvd. FAX: 650-964-0811
Mountain View, CA 94043 PP-ASEL-IA