mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-24 04:25:06 +02:00
15 lines
343 B
Scheme
15 lines
343 B
Scheme
(import (scheme base))
|
|
|
|
;; (let-syntax ((given-that (syntax-rules ()
|
|
;; ((given-that test stmt1 stmt2 ...)
|
|
;; (if test
|
|
;; (begin stmt1
|
|
;; stmt2 ...))))))
|
|
;; (let ((if #t))
|
|
;; (given-that if (set! if 'now))
|
|
;; if)) ;; => now
|
|
|
|
(let ((x 'outer))
|
|
(let-syntax ((m (syntax-rules () ((m) x))))
|
|
(let ((x 'inner))
|
|
(m)))) ;; Should be outer
|