-
Notifications
You must be signed in to change notification settings - Fork 130
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
Switch to make some operations rely on DOM instead of ECJ #1983
Switch to make some operations rely on DOM instead of ECJ #1983
Conversation
68f0523
to
0c11b2a
Compare
14408eb
to
1656b25
Compare
48eebfc
to
7052ee5
Compare
4330a3f
to
edba7c2
Compare
5a5ca09
to
7649a67
Compare
3c2413d
to
cb01ee7
Compare
f984518
to
b4bd774
Compare
8ebcc50
to
b5f5f0a
Compare
15cb481
to
57d72da
Compare
Introduced 2 system property switches to control whether some IDE operations are using ECJ parser (legacy/default) or whether to make those operations powered by a full DOM. * CompilationUnit.DOM_BASED_OPERATIONS will make codeSelect (hover, link to definition...), buildStructure (JDT Project element model), reconciler (code diagnostics feedback); this one seems currently working ✔ * CompilationUnit.codeComplete.DOM_BASED_OPERATIONS controls completion (unlike other operations, completion based on DOM is far from being complete or straightforward) 🏗️ * SourceIndexer.DOM_BASED_INDEXER controls whether the indexation of a source document should first build/use a full DOM. This one is currently incomplete 🏗️ The DOM-based operation can then allow to plug alternative compiler then ECJ and still get JDT functionalities working. Also-By: David Thompson <[email protected]> Also-By: Snjezana Peco <[email protected]>
The parser used to build AST isn't recovering as well as the selection parser. Let's disable those at the moment. They can be re-enabled is the parser used by ASTParser is made to recover better. Some other tests related to particular bugs in JDT are also skipped for the moment. We can't leverage Assume.assume... and skipped tests because those tests run with JUnit 3
554670c
to
e7c36d3
Compare
We won't work further on making JDT's DOM-first approach fully compatible with ECJ. It would still be a nice-to-have, but the remaining issues are hard to fix in ECJ and are not a requirement to fix them in order to enable alternative compiler backends, so no further work in planned on this topic. DOM-first is now fully included with DOM with Javac branch. |
FWIW, I'll probably rewrite this patch to not include the implementation, but just have an extension point allowing to define alternative startegies for
|
(continuation of #1863 as the source repo/branch changed)
Switch to make some operations rely on DOM instead of ECJ
Introduced 2 system property switches to control whether some IDE
operations are using ECJ parser (legacy/default) or whether to make
those operations powered by a full DOM.
The DOM-based operation can then allow to plug alternative compiler then ECJ and still get JDT functionalities working.