mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-23 20:15:05 +02:00
WIP
This commit is contained in:
parent
8e64b7a40d
commit
fa682dfbfd
1 changed files with 7 additions and 1 deletions
8
cgen.scm
8
cgen.scm
|
@ -149,15 +149,21 @@
|
|||
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)
|
||||
;;(write `(JAE DEBUG ,trace))
|
||||
(if (or (not (pair? trace))
|
||||
(null? (cdr trace)))
|
||||
""
|
||||
(string-append
|
||||
"Cyc_st_add(\""
|
||||
(car trace)
|
||||
":"
|
||||
(symbol->string (cdr trace)))))
|
||||
;; TODO: escape backslashes
|
||||
(symbol->string (cdr trace))
|
||||
"\");\n"
|
||||
)))
|
||||
|
||||
;; END st helpers
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue