diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-02-20 15:37:57 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-02-20 15:37:57 -0800 |
commit | 7e5dab1f846000c633baaf0642362ad79eb4f32e (patch) | |
tree | 46dc279443eb59b2ebdc8391c8f00069276917b0 /inst.nsi | |
parent | 19453cda77c282b59da9f6fe7b4b3eccb0979691 (diff) | |
download | txr-7e5dab1f846000c633baaf0642362ad79eb4f32e.tar.gz txr-7e5dab1f846000c633baaf0642362ad79eb4f32e.tar.bz2 txr-7e5dab1f846000c633baaf0642362ad79eb4f32e.zip |
compiler: constant folding: avoid shadowed funs.
* share/txr/stdlib/compiler.tl (compiler comp-arith-form):
Pass env to reduce-constant.
(compiler comp-fun-form): Likewise, and don't bother checking
%const-foldable% because reduce-constant does that again.
(compiler comp-apply-call): Pass env to reduce-constant.
(reduce-constant): Take env argument. If the function is
constant foldable, check that there is no lexical function
call binding shadowing it. If so, it's not the function we
think it is, and we must not constant-fold it.
Diffstat (limited to 'inst.nsi')
0 files changed, 0 insertions, 0 deletions