tree-sitter-python
tree-sitter-python copied to clipboard
Feature request: Syntax highlighting for using pipe as a union operator
In PEP 604, the pipe symbol (|) was implemented as a Union operator and when using it in cases such as the following, the types aren't recognized to be highlighted.
isinstance(5, int | str)
# or
def f(s: int | float) -> None:
print(s + 1)