mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-23 21:10:29 +02:00
Fix build of (language cps compile-js)
* module/language/cps/compile-js.scm (compile-js): Use lower-cps from (language cps compile-bytecode) rather than optimize, which is no longer there.
This commit is contained in:
parent
1b36a76ea4
commit
23f829b175
1 changed files with 2 additions and 10 deletions
|
@ -5,18 +5,10 @@
|
||||||
#:use-module (ice-9 match)
|
#:use-module (ice-9 match)
|
||||||
#:export (compile-js))
|
#:export (compile-js))
|
||||||
|
|
||||||
(define optimize (@@ (language cps compile-bytecode) optimize))
|
(define lower-cps (@@ (language cps compile-bytecode) lower-cps))
|
||||||
(define convert-closures (@@ (language cps compile-bytecode) convert-closures))
|
|
||||||
(define reify-primitives (@@ (language cps compile-bytecode) reify-primitives))
|
|
||||||
(define renumber (@@ (language cps compile-bytecode) renumber))
|
|
||||||
|
|
||||||
(define (compile-js exp env opts)
|
(define (compile-js exp env opts)
|
||||||
;; See comment in `optimize' about the use of set!.
|
(set! exp (lower-cps exp opts))
|
||||||
(set! exp (optimize exp opts))
|
|
||||||
(set! exp (convert-closures exp))
|
|
||||||
;; first-order optimization should go here
|
|
||||||
(set! exp (reify-primitives exp))
|
|
||||||
(set! exp (renumber exp))
|
|
||||||
(match exp
|
(match exp
|
||||||
(($ $program (($ $cont ks funs) ...))
|
(($ $program (($ $cont ks funs) ...))
|
||||||
;; TODO: I should special case the compilation for the initial fun,
|
;; TODO: I should special case the compilation for the initial fun,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue