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
Currently, a space is not needed between a numeric literal inside of a block and the end delimiter.
For example:
julia> struct Foo 3end
julia> begin 2end
2
julia> let; 8end
8
julia> let x=3; x^2end
9
There was some agreement in the Slack channel that this is weird.
It may not be weird enough to warrant action and is certainly not as entertaining as this oddity but seemed worth mentioning.
I also found this related example where numeric juxtaposition is parsed in one case but not the other:
julia> 10primitive type Bar 16 end
ERROR: MethodError: no method matching *(::Int64, ::Nothing)
Closest candidates are:
*(::Any, ::Any, ::Any, ::Any...) at operators.jl:529
*(::T, ::T) where T<:Union{Int128, Int16, Int32, Int64, Int8, UInt128, UInt16, UInt32, UInt64, UInt8} at int.jl:54
*(::Union{Int16, Int32, Int64, Int8}, ::BigInt) at gmp.jl:523
...
Stacktrace:
[1] top-level scope at REPL[46]:1
julia> 10struct Baz end
ERROR: syntax: extra token "struct" after end of expression
The text was updated successfully, but these errors were encountered:
Currently, a space is not needed between a numeric literal inside of a block and the
end
delimiter.For example:
There was some agreement in the Slack channel that this is weird.
It may not be weird enough to warrant action and is certainly not as entertaining as this oddity but seemed worth mentioning.
I also found this related example where numeric juxtaposition is parsed in one case but not the other:
The text was updated successfully, but these errors were encountered: