You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to match Julia syntax has some quirks that I think are worth documenting in some way, with maybe also a debug mode that warns when patterns that might not mean what they seem are used.
(*{args}) does not match a tuple, (*{args},) does, so things like (*{args}) -> ... could be warned against. Also, (*{args},) -> body will not match (x) -> y.
(x...)does match a tuple, so (a, b, (x...)) is suspicious and @metafunction f((args...)) = ... and @metafunction f(args...) = ... mean different things and either could not be what the author intended.
@m x *{args} matches @m x * {args}, with * unintentionally used in its binary form, same with [x *{elements}]. (maybe I should just change it to :*{args})
f() = expr; *{exprs} is the same as (f() = expr); *{exprs} instead of f() = (expr; *{exprs}).
There are more probably, will add to the list if I remember.
The text was updated successfully, but these errors were encountered:
Trying to match Julia syntax has some quirks that I think are worth documenting in some way, with maybe also a debug mode that warns when patterns that might not mean what they seem are used.
(*{args})
does not match a tuple,(*{args},)
does, so things like(*{args}) -> ...
could be warned against. Also,(*{args},) -> body
will not match(x) -> y
.(x...)
does match a tuple, so(a, b, (x...))
is suspicious and@metafunction f((args...)) = ...
and@metafunction f(args...) = ...
mean different things and either could not be what the author intended.@m x *{args}
matches@m x * {args}
, with*
unintentionally used in its binary form, same with[x *{elements}]
. (maybe I should just change it to:*{args}
)f() = expr; *{exprs}
is the same as(f() = expr); *{exprs}
instead off() = (expr; *{exprs})
.There are more probably, will add to the list if I remember.
The text was updated successfully, but these errors were encountered: