javac ast indices: do not index a symbol if qualifier has NONE type (in this case code is not compilable).

This commit is contained in:
Dmitry Batkovich
2017-06-19 14:39:56 +03:00
parent de00ea5149
commit 6cfaebdb0e
@@ -153,7 +153,7 @@ public interface JavacRef {
public static JavacElementRefBase fromElement(Element element, Element qualifier, JavacNameTable nameTableCache) {
if (qualifier != null) {
TypeMirror type = qualifier.asType();
if (type == null || type.getKind() == TypeKind.NONE) {
if (type == null || type.getKind() == TypeKind.NONE || type.getKind() == TypeKind.OTHER) {
return null;
}
}