Hi all! I saw the recent additions of tap/2 and then/2 to the Kernel and I was wondering, would it make sense to make them macros rather than functions?
Since this is pure syntactic sugar for control flow, like `if` or the pipe operator itself, I thought it could be nice to just generate the desired AST instead of adding the runtime overhead of a function call. But maybe I missed some implication of such a change, and a function is better in this case? I created a branch to try it out, for the discussion: https://github.com/elixir-lang/elixir/compare/master...sabiwara:macro_tap_then?expand=1 Looking forward to hearing your thoughts! -- You received this message because you are subscribed to the Google Groups "elixir-lang-core" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/39ffaaed-e880-4ead-87a9-83a210639969n%40googlegroups.com.
