Closed g0dzill3r closed 1 year ago
The scope needs to be preserved for bound procedures and lambdas so that they properly evaluate expressions in their closure.
This:
(define (foo x) (define (print-x) (display x) (newline)) (let ((x (+ x 1))) (print-x) ) (print-x) ) (foo 123)
prints:
124 123
but should print:
123 123
The scope needs to be preserved for bound procedures and lambdas so that they properly evaluate expressions in their closure.
This:
prints:
but should print: