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

Is "in" a keyword or word operator? #1056

Closed
edemaine opened this issue Jan 4, 2019 · 0 comments · Fixed by #1061
Closed

Is "in" a keyword or word operator? #1056

edemaine opened this issue Jan 4, 2019 · 0 comments · Fixed by #1061

Comments

@edemaine
Copy link
Contributor

edemaine commented Jan 4, 2019

According to https://docs.python.org/2.5/ref/keywords.html, in (and the whole regex in|is|and|or|not) should be considered keywords in Python, but they get recognized as "word operators". On the other hand, the CoffeeScript lexer treats in as a keyword. Could they be made consistent? (I have a preference for keyword, but would be happy either way.)

Context: I'm formatting a bunch of side-by-side examples of CoffeeScript and Python and I noticed that for ... in renders the in part differently in CoffeeScript (as keyword) than in Python (as word). Example:

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant