Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tokenize subclass list names in tree-sitter grammar #298

merged 1 commit into from Apr 10, 2019


None yet
2 participants
Copy link

commented Apr 6, 2019


  • Filling out the template is required. Any pull request that does not include enough information to be reviewed in a timely manner may be closed at the maintainers' discretion.
  • All new code requires tests to ensure against regressions

Description of the Change

This PR tokenizes the names of subclasses listed within class definitions, for Python files matched by the tree-sitter grammar.

Screen Shot 2019-04-06 at 2 09 32 PM

Screen Shot 2019-04-06 at 2 10 30 PM

Alternate Designs

I don't know if the Atom team desires to tokenize these subclass names differently; I figured entity.other.inherited-class was the most appropriate scope, as it's based on the same scope from the first-mate grammar.


Syntax highlighting that is more familiar to longtime users of the Python first-mate grammar.

Possible Drawbacks

Perhaps some might prefer different colors be used for the subclass names, though I personally like them.

Applicable Issues


@nathansobo nathansobo merged commit d901fb9 into atom:master Apr 10, 2019

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
continuous-integration/travis-ci/pr The Travis CI build passed

@nathansobo nathansobo self-assigned this Apr 10, 2019


This comment has been minimized.

Copy link

commented Apr 10, 2019

Cool of you to break these up. Far from a Python expert but this also seems reasonable.

@50Wliu 50Wliu referenced this pull request Apr 24, 2019


Atom 1.32 breaks syntax highlighting #281

1 of 1 task complete

@caleb531 caleb531 deleted the caleb531:tree-sitter-subclass-names branch May 12, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.