4 ms·
The Lua solution is clutter. Why return a boolean just to switch on it and then discard it?
by tamana 10y ago
The Lua solution is clutter. Why return a boolean just to switch on it and then discard it?
- Dylan16807 10y agoWhy create a lambda just to execute it and then discard it?
- eru 10y agoThe problem with the Boolean is rather that people mix up the two values all the time. The lambda also has more type safety. A Boolean is always a Boolean, but the compiler (and in a dynamic language the runtime) can tell you when you are calling your passed functions with the wrong arguments, because you mixed them up.