macro, quasiquote

21 views
Skip to first unread message

Minoru

unread,
Jun 19, 2026, 1:32:18 AM (11 days ago) Jun 19
to Extempore
Hi Ben,

My some macro functions didn't work in ver 0.9.4, then I found the reason.
The problem is not macro func but quasiquote macro, slice macro !
I think ver 0.9.4 is correct ....

These examples are in ver 0.9.4,

`(a b)           ;(a b)
(define *m1* 10) ;*m1*
`(*m1*)          ;(*m1*)
`(,*m1*)         ;(10)
`(,@*m1*)        ;error, but 10 in ver 0.8.9
`(',@*m1*)       ;error, but ((quote . 10)) in ver 0.8.9
`*m1*            ;*m1*
`,*m1*           ;10
`,@*m1*          ;error, not error with no answer, no response in ver 0.8.9 !!!

(define *m2* '(10))
`,@*m2*          ;10,  not error with no answer, no response in ver 0.8.9 !!!
`(,@*m2*)        ;(10)


(define-macro (t4 a1 . b1)
  `(list ,a1 ,@b1))

(t4 'a) ;(a)
(t4 'a 'b) ;(a b)


(define-macro (t5 a1 . b1)
  `(list ,a1 ',@b1))

(t5 'a)    ;error,  but (a NIL) in 0.8.9
(t5 'a 'b) ;(a 'b)
Reply all
Reply to author
Forward
0 new messages