3 ms·
Nim's macros look harder to use, with a fairly custom DSL in the AST (instead of, say, a simple datastructure like a nested map). I don't think you can pattern-
by pmarreck 9y ago
Nim's macros look harder to use, with a fairly custom DSL in the AST (instead of, say, a simple datastructure like a nested map). I don't think you can pattern-match on AST fragments, either, like you can in Elixir.
Scala macros cannot change its syntax, Elixir macros can I believe (to some extent).
- pathsjs 9y agoThe AST of Nim is a simple tree, the only thing is that the nodes of this tree are tagged with a kind that represents the kind of syntactic element, since the language is not homoiconic