mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-25 04:55:04 +02:00
Fixed up call trace outputs
This commit is contained in:
parent
fa682dfbfd
commit
a4c4ae94fc
1 changed files with 6 additions and 6 deletions
12
cgen.scm
12
cgen.scm
|
@ -148,11 +148,7 @@
|
||||||
(cons (car trace) fnc)
|
(cons (car trace) fnc)
|
||||||
trace))
|
trace))
|
||||||
|
|
||||||
TODO: don't just do this, need to output as valid C code...
|
|
||||||
TODO: try and output this as the first expression after all var declarations.
|
|
||||||
may require change where this is called, though
|
|
||||||
(define (st:->code trace)
|
(define (st:->code trace)
|
||||||
;;(write `(JAE DEBUG ,trace))
|
|
||||||
(if (or (not (pair? trace))
|
(if (or (not (pair? trace))
|
||||||
(null? (cdr trace)))
|
(null? (cdr trace)))
|
||||||
""
|
""
|
||||||
|
@ -1013,8 +1009,12 @@ TODO: try and output this as the first expression after all var declarations.
|
||||||
(if has-closure? 1 0)))
|
(if has-closure? 1 0)))
|
||||||
");\n");
|
");\n");
|
||||||
"") ; No varargs, skip
|
"") ; No varargs, skip
|
||||||
(st:->code trace)
|
(c:serialize
|
||||||
(c:serialize body " ") "; \n"
|
(c:append
|
||||||
|
(c-code (st:->code trace))
|
||||||
|
body)
|
||||||
|
" ")
|
||||||
|
"; \n"
|
||||||
"}\n"))
|
"}\n"))
|
||||||
formals*))))
|
formals*))))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue