Skip to content

Why calling a lambda in expressions causes an error #2885

@xbyte3

Description

@xbyte3

Code:

const A = function() {
    return 1
}
B = A() # <- Error: Cannot use void in expression position

Why calling a lambda in expressions causes an error "Cannot use void in expression position"? I think this is a 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