News for hackers. Stuff that matters.
Re:Why Lisp? by fit2rule on Friday May 08, 2015 @04:28AM (#9510546)
Your lame idiom example in java is why I love Lua so much:

    log.debug(debugIsEnabled and "yo expensive" or "yikes!")
Re:Why Lisp? by sirclueless on Friday May 08, 2015 @04:39AM (#9510568)
Calling log.debug() with and argument of `false` is a no-op? That sounds like someone bending the language to fit an idiom, because it doesn't sound like a sane API except that it enables this use case.
Re:Why Lisp? by spacemanmatt on Friday May 08, 2015 @09:20AM (#9511500)
It is insane in an eager-evaluated calling context. You're not wrong. But in Lisp it's not insane at all to let a macro consume a parameter and yield a no-op. Think of how this plays with a JIT and having code that can dynamically switch between dev/QA/production behavior and performance profiles, just for one example.