mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-12 06:41:13 +02:00
peval comment & reindentation
* module/language/tree-il/optimize.scm (peval): Add a comment regarding failure modes, and reindent one clause.
This commit is contained in:
parent
9581febbb0
commit
40bd6a7e57
1 changed files with 9 additions and 3 deletions
|
@ -450,8 +450,8 @@ it does not handle <fix> and <let-values>, it should be called before
|
||||||
(let* ((vals* (map (cut loop <> env calls) vals))
|
(let* ((vals* (map (cut loop <> env calls) vals))
|
||||||
(vals (map maybe-unconst vals vals*))
|
(vals (map maybe-unconst vals vals*))
|
||||||
(body* (loop body
|
(body* (loop body
|
||||||
(fold vhash-consq env gensyms vals)
|
(fold vhash-consq env gensyms vals)
|
||||||
calls))
|
calls))
|
||||||
(body (maybe-unconst body body*)))
|
(body (maybe-unconst body body*)))
|
||||||
(if (const? body*)
|
(if (const? body*)
|
||||||
body
|
body
|
||||||
|
@ -592,7 +592,13 @@ it does not handle <fix> and <let-values>, it should be called before
|
||||||
(($ <lambda>)
|
(($ <lambda>)
|
||||||
app)
|
app)
|
||||||
(($ <toplevel-ref>)
|
(($ <toplevel-ref>)
|
||||||
app))
|
app)
|
||||||
|
|
||||||
|
;; In practice, this is the clause that stops peval:
|
||||||
|
;; module-ref applications (produced by macros,
|
||||||
|
;; typically) don't match, and so this throws,
|
||||||
|
;; aborting peval for an entire expression.
|
||||||
|
)
|
||||||
|
|
||||||
app)))
|
app)))
|
||||||
(($ <lambda> src meta body)
|
(($ <lambda> src meta body)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue