mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-06 03:21:12 +07:00
[java-highlighting] Better call type mismatch reporting
GitOrigin-RevId: d1ed820188361e9104709793d5e5f4965f4cfc8b
This commit is contained in:
committed by
intellij-monorepo-bot
parent
f7aaa72829
commit
b2f80bd4db
@@ -1,13 +0,0 @@
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
public class Demo {
|
||||
void test() {
|
||||
Map<Long, List<String>> collect = <error descr="Incompatible types. Found: 'java.util.Map<java.lang.Integer,java.util.List<java.lang.String>>', required: 'java.util.Map<java.lang.Long,java.util.List<java.lang.String>>'">Stream.of("xyz", "asfdasdfdasf", "dasfafasdfdf")
|
||||
.collect(Collectors.groupingBy(s -> s.length()));</error>
|
||||
|
||||
Map<String, Long> map = <error descr="Incompatible types. Found: 'java.util.Map<java.lang.String,java.lang.Integer>', required: 'java.util.Map<java.lang.String,java.lang.Long>'">Stream.of("a", "b", "c").collect(Collectors.toMap(s -> s, s -> s.length()));</error>
|
||||
}
|
||||
}
|
||||
@@ -32,7 +32,6 @@ public class LightAdvHighlightingJdk8Test extends LightDaemonAnalyzerTestCase {
|
||||
public void testUncheckedWarningForPolyConditional() { enableInspectionTool(new UncheckedWarningLocalInspection()); doTest(true, true); }
|
||||
public void testUncheckedWarningOnQualifierWithTypeParameterType() { enableInspectionTool(new UncheckedWarningLocalInspection()); doTest(true, true); }
|
||||
public void testLambdaExpressions() { doTest(false, true); }
|
||||
public void testComplexStreamTypeMismatch() { doTest(false, false);}
|
||||
public void testUnsupportedFeatures() { doTest(false, false); }
|
||||
public void testModulesNotSupported() { doTest(false, false); }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user