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

Add pins in BNF to improve parsing performance #932

Merged
merged 10 commits into from Nov 6, 2019
Merged

Add pins in BNF to improve parsing performance #932

merged 10 commits into from Nov 6, 2019

Conversation

@ice1000
Copy link
Contributor

@ice1000 ice1000 commented Jun 18, 2019

Additions

Added some { pin=1 } or { pin=2 } to proper BNF rules to improve parsing performance and fault tolerance.

Changes

Regenerate parsers (in awe that some generated files are manually edited).

Backwards incompatible changes

Some Psi APIs are now returning nullable because the parser is now fault-tolerant: it also parses incomplete code as incomplete ASTs. Parsing errors will be displayed but code analysis can still run.

@ice1000
Copy link
Contributor Author

@ice1000 ice1000 commented Jun 18, 2019

All compilation errors are caused by manually-edited generated files. Will do some git-reverts.

Loading

@PHPirates
Copy link
Collaborator

@PHPirates PHPirates commented Jun 30, 2019

@HannahSchellekens Please resolve merge conflicts.

FWIW I tested this PR in the last alpha builds and didn't notice any problems.

Loading

# Conflicts:
#	src/nl/hannahsten/texifyidea/folding/LatexEnvironmentFoldingBuilder.kt
@ice1000
Copy link
Contributor Author

@ice1000 ice1000 commented Jul 1, 2019

@HannahSchellekens Please resolve merge conflicts.

FWIW I tested this PR in the last alpha builds and didn't notice any problems.

I have resolved merge conflicts.

Loading

HannahSchellekens and others added 2 commits Jul 2, 2019
All usage was already delegated to the PsiFile.referencedFileSet
extension method, so changing that method to use the ReferencedFileSetService
was enough for it to take effect.
Copy link
Member

@HannahSchellekens HannahSchellekens left a comment

Looking good, and thanks for the effort! Just one little formatting change which shouldn't be much of an issue.

Edit: for what I've tested it seems to work flawlessly.

Loading

@ice1000
Copy link
Contributor Author

@ice1000 ice1000 commented Jul 3, 2019

Fixed, please take a look @HannahSchellekens @PHPirates

Loading

@ice1000
Copy link
Contributor Author

@ice1000 ice1000 commented Jul 3, 2019

Travis failing, oh no

Loading

@ice1000
Copy link
Contributor Author

@ice1000 ice1000 commented Jul 3, 2019

Should be fixed by my force-push

Loading

@ice1000
Copy link
Contributor Author

@ice1000 ice1000 commented Jul 10, 2019

Merged master

Loading

@PHPirates PHPirates merged commit 3c8d194 into Hannah-Sten:master Nov 6, 2019
1 check passed
Loading
@ice1000 ice1000 deleted the pin branch Nov 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants