void () { myFixture.configureByText("Test.java", """ public class Test { interface BaseRecord<T> {} record ExtendedRecord1<T extends CharSequence> (T a,T b) implements BaseRecord<T>{} public static void wildcardWiderBound0(BaseRecord<?> variable1) { if (variable1 instanceof ExtendedRecord1(var a, var b)) { System.out.println(a + " " + b.length()); } } public static void wildcardWiderBound1(BaseRecord<? extends String> variable1) { if (variable1 instanceof ExtendedRecord1(var a, var b)) { System.out.println(a + " " + b.trim()); } } } """); myFixture.checkHighlighting(); }