mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Revert "IJ-CR-102037 [java-inspections] IDEA-311705. Support type inference changes in Java 20 for foreach"
This reverts commit ea173dc1bc9794b1acb6fcc97b3539bbd87319cd. GitOrigin-RevId: 6a0ecd9623a9cf1209b93e115e527a3579ea096d
This commit is contained in:
committed by
intellij-monorepo-bot
parent
026f64952a
commit
6678de5817
-1
@@ -316,7 +316,6 @@ public final class JavaGenericsUtil {
|
||||
PsiSubstitutor superClassSubstitutor = TypeConversionUtil.getClassSubstitutor(owner, aClass, substitutor);
|
||||
if (superClassSubstitutor == null) return null;
|
||||
PsiType itemType = superClassSubstitutor.substitute(typeParameter);
|
||||
itemType = PsiUtil.captureToplevelWildcards(itemType, aClass);
|
||||
return itemType == null ? PsiType.getJavaLangObject(manager, aClass.getResolveScope()) : itemType;
|
||||
}
|
||||
if (type instanceof PsiIntersectionType) {
|
||||
|
||||
-5
@@ -214,11 +214,6 @@ public class DeconstructionInferenceTest extends LightJavaCodeInsightFixtureTest
|
||||
int length = text.length();
|
||||
}
|
||||
}
|
||||
public static void test2(List<Box<? extends String>> records) {
|
||||
for (Box(var x ) : records) {
|
||||
System.out.println(x.isEmpty());
|
||||
}
|
||||
}
|
||||
}
|
||||
""");
|
||||
myFixture.enableInspections(new RawUseOfParameterizedTypeInspection());
|
||||
|
||||
Reference in New Issue
Block a user