mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 03:13:40 +07:00
raw diamond substitution: infer Object for jdk < 1.8 (IDEA-133733)
This commit is contained in:
+10
@@ -3,4 +3,14 @@ import java.util.*;
|
||||
class Sample {
|
||||
public static List getList() {return null;}
|
||||
List<Integer> list = new ArrayList<>(getList());
|
||||
|
||||
void foo() {
|
||||
barz<error descr="'barz(java.util.Map<java.lang.String,java.lang.String[]>)' in 'Sample' cannot be applied to '(java.util.HashMap<java.lang.Object,java.lang.Object>)'">(new HashMap<>(create()))</error>;
|
||||
}
|
||||
|
||||
Map create() {
|
||||
return null;
|
||||
}
|
||||
|
||||
void barz(Map<String, String[]> map) {}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user