Open korenmiklos opened 2 weeks ago
Check this trick in Chain.jl. Does not actually parse aside
macro, but checks whether there is a aside
macro call within your list of expressions.
With this trick, it is actually possible to use @if
like
@replace y = 0 @if y < 0
There is no macro if
, which is a reserved word. But @replace
can parse the above, including a macrocall to symbol @if
.
This is a hacky solution, and we run the risk of Julia removing this functionality in later parsers and compilers. I would introduce and document the keyword @where
, but mention that @if
is also available for better Stata compatibility.
now looks
We want this to be parsed in our own AST as