@ -333,7 +333,12 @@ public class ClassTypeResolver extends JavaParserVisitorAdapter {
|
||||
if (isMemberVisibleFromClass(typeToSearch.getType(), field.getModifiers(), accessingClass)) {
|
||||
return typeToSearch.resolveTypeDefinition(field.getGenericType());
|
||||
}
|
||||
} catch (NoSuchFieldException e) { /* swallow */ }
|
||||
} catch (final NoSuchFieldException ignored) {
|
||||
// swallow
|
||||
} catch (final NoClassDefFoundError e) {
|
||||
// TODO : report a missing class once we start doing that...
|
||||
return null;
|
||||
}
|
||||
|
||||
// transform the type into it's supertype
|
||||
typeToSearch = typeToSearch.resolveTypeDefinition(typeToSearch.getType().getGenericSuperclass());
|
||||
|
@ -5,6 +5,7 @@
|
||||
package net.sourceforge.pmd.typeresolution;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertNotNull;
|
||||
import static org.junit.Assert.assertNull;
|
||||
import static org.junit.Assert.assertSame;
|
||||
|
||||
|
Reference in New Issue
Block a user