~ chicken-core (chicken-5) d4393438bc97150fcc5a0d2b8c8f983a3e8c122a


commit d4393438bc97150fcc5a0d2b8c8f983a3e8c122a
Author:     felix <felix@call-with-current-continuation.org>
AuthorDate: Fri Oct 7 08:17:54 2011 +0200
Commit:     Christian Kellermann <ck@emlix.com>
CommitDate: Fri Oct 7 13:20:11 2011 +0200

        fix test for variable being always bound before optimizing the binding away
    
    Signed-off-by: Christian Kellermann <ckeen@pestilenz.org>

diff --git a/compiler.scm b/compiler.scm
index fef3bb7d..3b2a03bb 100644
--- a/compiler.scm
+++ b/compiler.scm
@@ -2126,7 +2126,7 @@
 			     (if (eq? '##core#variable (node-class value))
 				 (let ((varname (first (node-parameters value))))
 				   (or (not (get db varname 'global))
-				       (not (variable-mark varname '##core#always-bound))))
+				       (variable-mark varname '##core#always-bound)))
 				 (not (expression-has-side-effects? value db)) ))
 			undefined) )
 	   (quick-put! plist 'removable #t) )
Trap