Skip to content

Better Error Message For Incorrect -> Arrow In Closure? #18512

Open
@JimLynchCodes

Description

@JimLynchCodes

Coming from the TypeScript world it's easy to accidentally add an arrow "->" when doing a one-liner closure, but I feel like this is a very cryptic error message that it gives...


Image


Is there any way to have it suggest , "if you meant for this to be a closure, remove the arrow"?


Thanks! 👍 🦀


Metadata

Metadata

Assignees

No one assigned

    Labels

    A-parserparser issuesC-featureCategory: feature request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions