2017-02-27 12:00:24 -05:00
|
|
|
---
|
|
|
|
Test
|
|
|
|
---
|
2017-03-02 16:36:23 -05:00
|
|
|
A simple lexical closure.
|
|
|
|
|
2017-03-06 12:44:06 -05:00
|
|
|
| script | lisp interpreter fixture |
|
|
|
|
| show | evaluate text | (defun adder-x (x) (lambda (y) (+ x y))) |
|
2017-03-07 16:41:26 -05:00
|
|
|
| show | evaluate text | (setq adder-20 (adder-x 20)) |
|
2017-03-06 12:44:06 -05:00
|
|
|
| check | evaluate text | (funcall adder-20 2) | 22 |
|