summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2018-03-20 20:55:43 -0700
committerKaz Kylheku <kaz@kylheku.com>2018-03-20 20:55:43 -0700
commita2af58223a04b0030fd7f43e38cf33f4fb230983 (patch)
treebd0503a34e2fac51534cf76beed2236690c24e5f
parentab4dfc9532b72256fc38543650093882868b036f (diff)
downloadtxr-a2af58223a04b0030fd7f43e38cf33f4fb230983.tar.gz
txr-a2af58223a04b0030fd7f43e38cf33f4fb230983.tar.bz2
txr-a2af58223a04b0030fd7f43e38cf33f4fb230983.zip
compiler: lambda bug: wrong reg in defaulting.
* share/txr/stdlib/compiler.tl (compiler comp-lambda): To determine whether the argument is missing, we must test it for equivalence to the : symbol. What we're testing here is the wrong thing: the register which will hold the output of the default initform. That fragment would even be executed yet at this spot in the code, never mind being the wrong value to test.
-rw-r--r--share/txr/stdlib/compiler.tl2
1 files changed, 1 insertions, 1 deletions
diff --git a/share/txr/stdlib/compiler.tl b/share/txr/stdlib/compiler.tl
index c65acb56..986902a3 100644
--- a/share/txr/stdlib/compiler.tl
+++ b/share/txr/stdlib/compiler.tl
@@ -398,7 +398,7 @@
(lskip (gensym "l")))
^(,*(if have-sym
^((mov ,have-bind.loc ,tee-reg)))
- (ifq ,ifrg.oreg ,col-reg ,lskip)
+ (ifq ,vbind.loc ,col-reg ,lskip)
,*(if have-sym
^((mov ,have-bind.loc nil)))
,*ifrg.code