eerolanguage / eero

Eero was a fully binary- and header-compatible dialect of Objective-C, implemented with a modified version of the Apple-sponsored LLVM/clang open-source compiler. It featured a streamlined syntax, Python-like indentation, and other features that improve readability and code safety. It was inspired by languages such as Smalltalk, Python, and Ruby.
https://web.archive.org/web/20171101134337/http://eerolanguage.org/
288 stars 7 forks source link

Remove need for "return" keyword in compact blocks. #37

Open andyarvanitis opened 11 years ago

andyarvanitis commented 11 years ago

This was a request/suggestion made by a user via email. Compact blocks (not normal blocks) would implicitly return the result of the expression. Also consider allowing "return" keyword to be optional. Example compact blocks from documentation page would change to:

xyblock := (int x, int y | x + y)

descriptions := mylist.mapWith: (id element | element.description)