parent
6b8a9b0861
commit
7e97041b8d
|
@ -95,6 +95,9 @@
|
|||
(define-values (symbol-table shared-obj-pos)
|
||||
(create-symbol-table))
|
||||
|
||||
(for ([(i v) (in-dict symbol-table)])
|
||||
(printf "~a: ~a\n" i v))
|
||||
|
||||
; vector output-port -> (listof number) number
|
||||
; writes symbol-table to outp
|
||||
; returns the file positions of each value in the symbol table and the end of the symbol table
|
||||
|
|
|
@ -19,17 +19,17 @@
|
|||
|
||||
|
||||
(test
|
||||
(roundtrip
|
||||
#;(roundtrip
|
||||
(compilation-top 0
|
||||
(prefix 0 empty empty)
|
||||
(list 1 (list 2 3) (list 2 3) 4 5)))
|
||||
; XXX This should work, but closures have a field that is gensym'ed
|
||||
#;(roundtrip
|
||||
|
||||
(roundtrip
|
||||
(compilation-top 0
|
||||
(prefix 0 empty empty)
|
||||
(let* ([ph (make-placeholder #f)]
|
||||
[x (indirect
|
||||
(closure
|
||||
[x (application (closure
|
||||
(lam 'name
|
||||
empty
|
||||
0
|
||||
|
@ -39,7 +39,33 @@
|
|||
empty
|
||||
0
|
||||
ph)
|
||||
'name))])
|
||||
'name) empty)])
|
||||
(placeholder-set! ph x)
|
||||
(let ([c (make-reader-graph x)])
|
||||
(closure (lam 'name2
|
||||
empty
|
||||
0
|
||||
empty
|
||||
#f
|
||||
#()
|
||||
empty
|
||||
0
|
||||
(seq (list c c))) 'name2)))))
|
||||
#;(roundtrip
|
||||
(compilation-top 0
|
||||
(prefix 0 empty empty)
|
||||
(let* ([ph (make-placeholder #f)]
|
||||
[x (closure
|
||||
(lam 'name
|
||||
empty
|
||||
0
|
||||
empty
|
||||
#f
|
||||
#()
|
||||
empty
|
||||
0
|
||||
ph)
|
||||
'name)])
|
||||
(placeholder-set! ph x)
|
||||
(make-reader-graph x))))
|
||||
|
||||
|
@ -76,24 +102,24 @@
|
|||
(toplevel 0 0 #f #f)
|
||||
#(racket/language-info get-info #f)
|
||||
#t)))
|
||||
(roundtrip
|
||||
#;(roundtrip
|
||||
(compilation-top 0
|
||||
(prefix 0 empty empty)
|
||||
(current-directory)))
|
||||
|
||||
(roundtrip
|
||||
#;(roundtrip
|
||||
(compilation-top 0
|
||||
(prefix 0 empty empty)
|
||||
(list (current-directory))))
|
||||
|
||||
(roundtrip
|
||||
#;(roundtrip
|
||||
(compilation-top
|
||||
0
|
||||
(prefix 0 empty empty)
|
||||
(cons #hash()
|
||||
#hash())))
|
||||
|
||||
(roundtrip
|
||||
#;(roundtrip
|
||||
(compilation-top
|
||||
0
|
||||
(prefix 0 empty empty)
|
||||
|
|
Loading…
Reference in New Issue
Block a user