aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog5
-rw-r--r--src/interp/compiler.boot19
2 files changed, 14 insertions, 10 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index dcbf4bc6..4c2466d0 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,10 @@
2011-12-06 Gabriel Dos Reis <gdr@cs.tamu.edu>
+ * interp/compiler.boot (setqMultipleExplicit): Introduced
+ temporary variables are local to the assignment.
+
+2011-12-06 Gabriel Dos Reis <gdr@cs.tamu.edu>
+
* interp/compiler.boot (compResolveCall): Update description.
(compRetractGuard): Tidy.
(compRecoverDomain): Likewise.
diff --git a/src/interp/compiler.boot b/src/interp/compiler.boot
index d2dfd84b..59ea4e90 100644
--- a/src/interp/compiler.boot
+++ b/src/interp/compiler.boot
@@ -1022,17 +1022,16 @@ setqMultipleExplicit(nameList,valList,m,e) ==
#nameList~=#valList =>
stackMessage('"Multiple assignment error; # of items in: %1b must = # in: %2",[nameList,valList])
gensymList:= [genVariable() for name in nameList]
- assignList:=
- --should be fixed to declare genVar when possible
- [[.,.,e]:= compSetq1(g,val,$EmptyMode,e) or return "failed"
- for g in gensymList for val in valList]
- assignList="failed" => nil
- reAssignList:=
- [[.,.,e]:= compSetq1(name,g,$EmptyMode,e) or return "failed"
+ bindings := --should be fixed to declare genVar when possible
+ [insn.args for g in gensymList for val in valList
+ | [insn,.,e] := compSetq1(g,val,$EmptyMode,e) or leave "failed" ]
+ bindings is "failed" => nil
+ reAssignList :=
+ [[.,.,e] := compSetq1(name,g,$EmptyMode,e) or return "failed"
for g in gensymList for name in nameList]
- reAssignList="failed" => nil
- [['%seq,:[T.expr for T in assignList],:[T.expr for T in reAssignList]],
- $NoValueMode, last(reAssignList).env]
+ reAssignList is "failed" => nil
+ [['%bind,bindings,['%seq,:[T.expr for T in reAssignList]]],
+ $NoValueMode, last(reAssignList).env]
--% Quasiquotation