You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
446 B
Racket
18 lines
446 B
Racket
5 years ago
|
#lang br
|
||
|
(provide #%top-interaction #%module-begin
|
||
|
(rename-out [my-datum #%datum]
|
||
|
[my-datum #%top]
|
||
|
[my-app #%app]))
|
||
|
|
||
|
(define-macro (my-datum . THING)
|
||
|
(define datum (syntax->datum #'THING))
|
||
|
(cond
|
||
|
[(string? datum) #'"whee"]
|
||
|
[(number? datum) #'42]
|
||
|
[else #''kaboom]))
|
||
|
|
||
|
(define-macro (my-app FUNC . ARGS)
|
||
|
#'(list FUNC . ARGS))
|
||
|
|
||
|
(module reader syntax/module-reader
|
||
|
injunction-demo)
|