Can't get ITranslationUnit for creating an AST of an C-File within a Eclipse Plugin
问题 I'm trying to generate an AST with help of the CDT Eclipse Framework from an C-File of a generated project in my workspace. But every time i try to get an TranslationUnit through ICElement ice = CoreModel.getDefault().create(file); ITranslationUnit tu= (ITranslationUnit) ice; ice and tu are null and i get the following error java.lang.NullPointerException at org.eclipse.cdt.internal.core.pdom.TeamPDOMImportOperation.expandLocation(TeamPDOMImportOperation.java:135) at org.eclipse.cdt.internal