0

There is a NodeFinder in org.eclipse.jdt.core.dom that can find the ASTNode in a given source code range. However, I am using a library that has ecj.jar as its Java compiler. The package org.eclipse.jdt.internal.compiler.ast in ECJ looks very similar to org.eclipse.jdt.core.dom, but I don't know how to get the ASTNode in a source range. I can't find documentation/source code for ecj.jar. Google search for either "ecj" or "Eclipse Compiler for Java" directed me to the EClipse JDT Core page, which doesn't have doc for org.eclipse.jdt.internal.compiler.ast. Any help?

Also, I am curious about why Eclipse has two Java compilers, that confuse me a lot.

1 Answer 1

0

It turned out that writing a NodeFinder for ecj was not hard. I wrote one and customized it for my special case.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.