Skip to content
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

Parse &xas a call expression #34693

Open
GunnarFarneback opened this issue Feb 7, 2020 · 2 comments
Open

Parse &xas a call expression #34693

GunnarFarneback opened this issue Feb 7, 2020 · 2 comments
Labels
breaking This change will break code needs decision A decision on this change is needed parser Language parsing and surface syntax

Comments

@GunnarFarneback
Copy link
Contributor

In #6080 (comment) @JeffBezanson wrote:

Deprecation is in for 0.7. For 1.0, we should change the parsing of &x to a call expression.

This doesn't seem to have happened, cf https://discourse.julialang.org/t/ampersand-operator-not-consistent-with-help/34266. Is this something that can be changed for 1.x or would it have to wait for 2.0?

@JeffBezanson JeffBezanson added breaking This change will break code parser Language parsing and surface syntax labels Feb 7, 2020
@JeffBezanson
Copy link
Member

Given possible uses of &x syntax, the question is whether it's more useful for &(1, 2) to be the same as 1 & 2, or for it to apply & to the single tuple (1, 2).

@StefanKarpinski StefanKarpinski added the needs decision A decision on this change is needed label Feb 7, 2020
@JeffreySarnoff
Copy link
Contributor

If &(true, false) is going to remain a syntax error until ampersand(..) is designed and implemented, then please reconsider introducing and, or [ like xor, if \xor were ascii ] and supporting or(p, qs....), and(p, qs...) as Boolean operators.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking This change will break code needs decision A decision on this change is needed parser Language parsing and surface syntax
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants