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 'maybe' as an atom before OTP 25 #1011

Closed
wants to merge 1 commit into from

Conversation

kvakvs
Copy link
Collaborator

@kvakvs kvakvs commented Jul 1, 2023

Closes #1009

Need good review

Need assistance, because this has several problems

  1. Switching SDK does not regenerate the editor with feature disabled or enabled, IDEA restart works. Need to invalidate all results of lexer somehow, when SDK changes.
  2. Need a project instance to pass to new ErlangLexer() in
    1. org/intellij/erlang/search/ErlangFindUsagesProvider.java
    2. org/intellij/erlang/editor/ErlangSyntaxHighlighter.java

@ignatov
Copy link
Owner

ignatov commented Jul 6, 2023

Hi there! Thank you for the PR. From my personal experience, it's much easier to absorb all the changes into the grammar and highlight any wrong or outdated structures with a dedicated inspection.

@ignatov
Copy link
Owner

ignatov commented Jul 6, 2023

Ah, my fault. I see that one: https://github.com/ignatov/intellij-erlang/blob/master/src/org/intellij/erlang/inspection/Erlang25SyntaxInspection.java

And I got the idea – with the older versions we have to parse it as an atom. Hmm, maybe we can retoken it back in the parser. I'll think on how to do better.

@ignatov ignatov closed this in bdc8368 Jul 11, 2023
@ignatov
Copy link
Owner

ignatov commented Jul 11, 2023

merged manually, thanks for your contribution

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 this pull request may close these issues.

Syntax error on `maybe' function in editor
3 participants