new inference: non wildcard parametrization: reject primitive bounds

This commit is contained in:
Anna Kozlova
2014-03-03 13:43:47 +01:00
parent ab2348a911
commit eb3695fffc
4 changed files with 20 additions and 3 deletions
@@ -0,0 +1,13 @@
class IDEA100385 {
void foo(N<Double> n){
n.forEach((<error descr="Incompatible parameter types in lambda expression">double e</error>) -> { });
}
static interface N<E> {
void forEach(Consumer<? extends E> consumer);
}
interface Consumer<T> {
public void accept(T t);
}
}