Skip to content

local variables with name package result in a syntax error #18

@baroquebobcat

Description

@baroquebobcat

We should either document this / make it a clearer error, or we could change it to be allowed. Allowing it would make some things more tricky perhaps.

$ mirah -e 'package = 1234;puts package'

DashE:1:

ERROR: expected dotted_name before ' = 1234;puts '
package = 1234;puts package
       ^
DashE parsed to nil
1 errors

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