fredrikekre/Runic.jl

Multiline generator-type syntax in a function is parsed incorrectly

Closed this issue · 0 comments

all(true for i in
    1
)

is converted into

all(
    true for i in
        1,
)

This new form does not parse correctly. It does pass if no function is provided, i.e. without all (but keeping ( )) it works fine. If not for the trailing comma after the iterator set this would be fine

The parse error is

julia> all(
           true for i in
               1,
       )
ERROR: ParseError:
# Error @ c:\Users\danjv\__test1.jl:4:1
        1,
)
╙ ── unexpected `)`
Stacktrace:
 [1] top-level scope
   @ c:\Users\danjv\__test1.jl:4