mirror of
https://github.com/justinethier/cyclone.git
synced 2025-07-10 22:37:38 +02:00
WIP
This commit is contained in:
parent
12d16dfbbe
commit
d549722cc4
2 changed files with 7 additions and 6 deletions
|
@ -882,7 +882,11 @@
|
|||
(cond
|
||||
((const? exp) exp)
|
||||
((prim? exp) exp)
|
||||
((ref? exp) exp)
|
||||
((ref? exp)
|
||||
(let ((renamed (assoc exp local-renamed)))
|
||||
(if renamed
|
||||
(cdr renamed) ;; Extract renamed symbol
|
||||
exp)))
|
||||
((quote? exp) exp)
|
||||
;; TODO: rename all lambda formals and update rename-env accordingly.
|
||||
;; will also require renaming refs later on here in expand...
|
||||
|
@ -898,10 +902,7 @@
|
|||
(map cdr a-lookup)
|
||||
ltype))
|
||||
)
|
||||
`(lambda ,(lambda->formals exp)
|
||||
;; TODO: want this line instead of the above, but need to solve a crash
|
||||
;; when compiling unit tests first (!!!)
|
||||
;`(lambda ,new-formals ;,(lambda->formals exp)
|
||||
`(lambda ,new-formals ;,(lambda->formals exp)
|
||||
,@(_expand-body
|
||||
'()
|
||||
(lambda->exp exp)
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
(let ((x 'outer))
|
||||
;(let-syntax ((m (syntax-rules () ((m) x))))
|
||||
(let ((x 'inner))
|
||||
(list)))) ;; Should be outer
|
||||
(x)))) ;; Should be outer
|
||||
; )
|
||||
;;;; Just testing, may want to remove this one once the recursive macro expansion works
|
||||
;;; (define-syntax my-or2 (syntax-rules ()
|
||||
|
|
Loading…
Add table
Reference in a new issue