Lec32-Macros
Contents
Macros
quote or unquote
在于怎么eval 🤔
,
后面的 (some_expression)
不会被quote
Macros in Scheme
define new special form in scheme…
define-macro
定义一个新的宏,接收一个 <expression>
作为参数,返回一个新的<expression>
并且eval之, 先不对参数eval
注意和define的区别,define在意的是传进来的 value
another example, to show info of your expression using macro
|
|
For Macro in Scheme
|
|
|
|
|
|
Trace
|
|
scheme example, without using macro
with using macro