Skip to content

Leaf kinds we don't expect #136

@mlechu

Description

@mlechu
julia> jlower("&")
ERROR: LoweringError:
&
╙ ── invalid syntax

julia> jlower("function (&)(::Int); 1; end")
ERROR: LoweringError:
function (&)(::Int); 1; end
#         ╙ ── Invalid function name

&, unless it's being called, is K"&" instead of K"Identifier". | and : behave the same. Are there others? How do I find out?

I think I'll fix this by converting any unknown leaf kind with a name_val to a K"Identifier" in EST so they're more consistent with Expr and easier to handle. Opening an issue to remember, and to consider changing the text->RawGreenNode behaviour instead since this could be called a parser bug.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions