Skip to content

Locations on Identifiers and other node types are incorrect #74

Description

@undauntedmark

When using the parser with the option loc: true, there are many cases where the locations show the same line/column numbers for the start and end of the node.

The common case is Identifiers, though this also seems to appear in other places like in VariableDeclarations and NumberLiterals. The attached file shows a basic reproducer along with the AST that run.js produces when {loc: true} is added to the parse invocation. All of the Identifier locations are incorrect in the JSON.

Repro.sol.txt
Repro.sol.json.txt

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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