Open ChrHorn opened 1 year ago
Scoped identifiers were originally only used for import statements. I added them to other places where I don't think it makes sense to have a field expression (like function signatures) for the same reason we distinguish between parameters and arguments. Parameters are restricted to symbol-like things, but arguments allow any primary expression.
There are a couple of things that do need to get fixed tho:
There's two ways to call scoped macros, but only one is parsed correctly:
@M.foo x y z # ok
M.@foo x y z # not parsed correctly
quoted operators like Base.:+
are not parsed correctly either.
scoped_identifier is also currently defined recursively
Yes, that needs to get fixed too.
These are used in different places but represent nearly the same syntax. I don't think we need both.
scoped_identifier
is also currently defined recursively. Recursive structures of arbitrary depth are very hard to query. A flat structure would be better.