Skip to content

Python2 compatability broken #7

Description

@talwrii
>>> pip install antlr-ast; python -c   'import antlr4'
Collecting antlr-ast
Collecting antlr4-python3-runtime (from antlr-ast)
Installing collected packages: antlr4-python3-runtime, antlr-ast
Successfully installed antlr-ast-0.2.0 antlr4-python3-runtime-4.7
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/tom/.local/lib/python2.7/site-packages/antlr4/__init__.py", line 1, in <mo
dule>
    from antlr4.Token import Token
  File "/home/tom/.local/lib/python2.7/site-packages/antlr4/Token.py", line 59
    def text(self, text:str):
                       ^
SyntaxError: invalid syntax

There is a question of whether you want to still support python2. Though one imagines you might want to more clearly exclude it.

This came up when working on latex2sympy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions