Runic creates unparsable code in a case with macro on a block
Closed this issue · 0 comments
KristofferC commented
using Runic: format_string
code = """
f(@m begin
end)
"""
new_code = format_string(code)
#=
julia> print(new_code)
f(
@m begin
end,
)
=#
JuliaSyntax.parseall(JuliaSyntax.GreenNode, new_code; version=v"2-")
#=
ERROR: ParseError:
# Error @ line 4:1
end,
)
╙ ── unexpected `)`
=#
Reduced from this code block https://github.com/JuliaLang/julia/blob/df1976d500914bebd5651bf56c13153f49e153f9/stdlib/REPL/src/LineEdit.jl#L201-L220