Why does resolveBinding() return null even though I setResolveBindings(true) on my ASTParser?
问题 I am writing an Eclipse plug-in that uses JDT AST's ASTParser to parse a method. I am looking within that method for the creation of a particular type of object. When I find a ClassInstanceCreation , I call getType() on it to see what type is being instantiated. I want to be sure that the fully-resolved type being dealt with there is the one I think it is, so I tell the resultant Type object to resolveBinding() . I get null back even though there are no compilation errors and even though I