mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-24 12:20:20 +02:00
Remove $void CPS expression type
* module/language/cps.scm: Remove the $void expression type, replaced by $const of the unspecified value. * module/language/cps/arities.scm: * module/language/cps/closure-conversion.scm: * module/language/cps/compile-bytecode.scm: * module/language/cps/cse.scm: * module/language/cps/dce.scm: * module/language/cps/dfg.scm: * module/language/cps/effects-analysis.scm: * module/language/cps/reify-primitives.scm: * module/language/cps/renumber.scm: * module/language/cps/self-references.scm: * module/language/cps/simplify.scm: * module/language/cps/slot-allocation.scm: * module/language/cps/specialize-primcalls.scm: * module/language/cps/types.scm: * module/language/cps/verify.scm: * module/language/tree-il/compile-cps.scm: Update callers.
This commit is contained in:
parent
1f3babaaef
commit
a9ec16f9c5
17 changed files with 33 additions and 47 deletions
|
@ -1,6 +1,6 @@
|
|||
;;; Continuation-passing style (CPS) intermediate language (IL)
|
||||
|
||||
;; Copyright (C) 2013, 2014 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 2013, 2014, 2015 Free Software Foundation, Inc.
|
||||
|
||||
;;;; This library is free software; you can redistribute it and/or
|
||||
;;;; modify it under the terms of the GNU Lesser General Public
|
||||
|
@ -122,7 +122,7 @@
|
|||
$kreceive $kargs $kfun $ktail $kclause
|
||||
|
||||
;; Expressions.
|
||||
$void $const $prim $fun $closure $branch
|
||||
$const $prim $fun $closure $branch
|
||||
$call $callk $primcall $values $prompt
|
||||
|
||||
;; First-order CPS root.
|
||||
|
@ -188,7 +188,6 @@
|
|||
(define-cps-type $kclause arity cont alternate)
|
||||
|
||||
;; Expressions.
|
||||
(define-cps-type $void)
|
||||
(define-cps-type $const val)
|
||||
(define-cps-type $prim name)
|
||||
(define-cps-type $fun free body) ; Higher-order.
|
||||
|
@ -264,10 +263,9 @@
|
|||
|
||||
(define-syntax build-cps-exp
|
||||
(syntax-rules (unquote
|
||||
$void $const $prim $fun $closure $branch
|
||||
$const $prim $fun $closure $branch
|
||||
$call $callk $primcall $values $prompt)
|
||||
((_ (unquote exp)) exp)
|
||||
((_ ($void)) (make-$void))
|
||||
((_ ($const val)) (make-$const val))
|
||||
((_ ($prim name)) (make-$prim name))
|
||||
((_ ($fun free body)) (make-$fun free (build-cps-cont body)))
|
||||
|
@ -380,8 +378,6 @@
|
|||
;; Calls.
|
||||
(('continue k exp)
|
||||
(build-cps-term ($continue k (src exp) ,(parse-cps exp))))
|
||||
(('void)
|
||||
(build-cps-exp ($void)))
|
||||
(('const exp)
|
||||
(build-cps-exp ($const exp)))
|
||||
(('prim name)
|
||||
|
@ -441,8 +437,6 @@
|
|||
;; Calls.
|
||||
(($ $continue k src exp)
|
||||
`(continue ,k ,(unparse-cps exp)))
|
||||
(($ $void)
|
||||
`(void))
|
||||
(($ $const val)
|
||||
`(const ,val))
|
||||
(($ $prim name)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue