smalltalk-tng
view etng-r2/how-to-save-on-brackets.txt @ 321:c4a0718c2d3c
Sketch of dependencies
| author | Tony Garnock-Jones <tonygarnockjones@gmail.com> |
|---|---|
| date | Sat Oct 08 15:36:03 2011 -0400 (7 months ago) |
| parents | |
| children |
line source
1 So currently {} is non-self-capturing and [] is self-capturing. What
2 if instead, the keyword "rec" (either "record" (== object) or
3 "recursive") were used to introduce a self-binding/open-recursion?
5 { x -> x + 1 } { x -> x + 1 }
7 rec { x -> x + 1 } [ x -> x + 1 ]
9 It provides a nice place to put a name for self, too, if we decide
10 that's a good idea:
12 rec self { x -> x + 1 }
