void () { // Examples from JEP 432 myFixture.configureByText("Test.java", """ record Box<T>(T t) {} class X { static void test1(Box<String> bo) { if (bo instanceof Box<String>(var s)) { System.out.println("String " + s.trim()); } } static void test2(Box<String> bo) { if (bo instanceof Box(var s)) { System.out.println("String " + s.trim()); } } static void test3(Box<Box<String>> bo) { if (bo instanceof Box<Box<String>>(Box(var s))) { System.out.println("String " + s.trim()); } } static void test4(Box<Box<String>> bo) { if (bo instanceof Box(Box(var s))) { System.out.println("String " + s.trim()); } } } """); myFixture.enableInspections(new RawUseOfParameterizedTypeInspection()); myFixture.checkHighlighting(); }