-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
add syntax for empty n-dimensional arrays #41618
Conversation
Nice, you didn't even have to touch Currently the parser allows this:
Line breaks between semicolons produce an error normally:
|
Oh, weird, I thought the |
3625917
to
5f70f92
Compare
test/syntax.jl
Outdated
@test Int[;;] == Array{Int}(undef, 0, 0) | ||
@test Int[;;;] == Array{Int}(undef, 0, 0, 0) | ||
|
||
@test_throws ParseError Meta.parse("[ ;]") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure that leading/trailing spaces should be an error...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I think I agree. Will change it.
bump? |
5f70f92
to
4669694
Compare
Probably better to not backport this PR at this point. |
Why probably not better to backport? If 1.7 ends up as LTS, then it's very useful to have all new syntax in. [I believe syntax can't be added with Compat.jl.] |
1.7 won't become the LTS. The same argument could be made for any feature. 1.7 is already taking longer to finalize than usual, so I don't think we should stretch that out any further by backporting additional feature. |
This should be ready, @JeffBezanson do you want to give this a review? |
70ead55
to
571620a
Compare
Might be worth backporting to 1.7 for consistency? Otherwise, this should probably have a NEWS entry.
closes #41389
cc: @BioTurboNick