David Chisnall wrote:
Blocks were in Smalltalk right from the start. They are one of the
fundamental features of most object oriented languages. The syntax
is, I agree, quite ugly, but they're one of the fundamental building
blocks of object oriented languages. JavaScript and Self manage a
rich object system with just dictionaries and blocks.
After using Pragmatic Smalltalk for a bit, the main thing I missed
when returning to Objective-C was the BlockClosure class. With
Objective-C 2, I can use blocks in Objective-C code, and it makes
life a lot easier for a whole lot of things (sorting, filtering,
visitor pattern...).
Indeed. Higher-order features (like blocks) were maybe made popular by
functional languages, but they are in no way restricted to functional
languages.
Wolfgang
_______________________________________________
Discuss-gnustep mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnustep