-
-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rethinking the .
AST
#324
Labels
Comments
CC @BenChung - I imagine you might have encountered this AST inconsistency before :-) |
I wholeheartedly support the idea of parsing |
Thanks for the second opinion!! PR almost done :-D |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I was working a bit on macro expansion - particularly
quote
(quasiquote) expansion with$
interpolations - and I've found that it's weird and inconvenient that we parsea.b
into(. a (quote b))
.Specifically, the part that's weird here is that we emit
(quote b)
for the field name even though this is "not quote syntax": this should not yield a syntax literal during lowering, and is thus a semantic mismatch with actual quote syntax of the form:(a + b)
orquote a+b end
.Q & A:
a.(b)
syntax to meangetfield(a, b)
, which would naturally have been parsed as(. a b)
. However this was deprecated as part of adding broadcast syntax in WIP: implement f.(args...) as a synonym for broadcast(f, args...) julia#15032I propose we just parse
a.b
as(. a b)
with the second argument implied to be a field name.The text was updated successfully, but these errors were encountered: