Runtime evaluation/In an environment: Difference between revisions
Content added Content deleted
m (→{{header|Factor}}: fix a typo, demonstrate the non-global status of x) |
m (→{{header|Factor}}: remove some whitespace) |
||
Line 266: | Line 266: | ||
tuck |
tuck |
||
[ [ x ] dip [ ( -- y ) eval ] curry with-variable ] 2bi@ - ;</lang> |
[ [ x ] dip [ ( -- y ) eval ] curry with-variable ] 2bi@ - ;</lang> |
||
<lang factor>IN: scratchpad 9 4 "x get dup * |
<lang factor>IN: scratchpad 9 4 "x get dup *" eval-with-x . |
||
65 |
65 |
||
IN: scratchpad x get . |
IN: scratchpad x get . |