mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 00:11:26 +07:00
bad return type in lambda expression: requited type added; range corrected (IDEA-134942)
This commit is contained in:
+1
-1
@@ -9,7 +9,7 @@ class Test {
|
||||
|
||||
<R> SuperFoo<R> foo(I<R> ax) { return null; }
|
||||
|
||||
SuperFoo<String> ls = foo(<error descr="Incompatible return type Foo<X> in lambda expression">() -> new Foo<>()</error>);
|
||||
SuperFoo<String> ls = foo(() -> <error descr="Bad return type in lambda expression: Foo<X> cannot be converted to SuperFoo<R>">new Foo<>()</error>);
|
||||
SuperFoo<Integer> li = foo(() -> new Foo<>());
|
||||
SuperFoo<?> lw = foo(() -> new Foo<>());
|
||||
}
|
||||
+1
-1
@@ -13,7 +13,7 @@ class Test {
|
||||
}
|
||||
|
||||
void bar(C c) {
|
||||
foo(c, <error descr="Incompatible return type A in lambda expression">x -> x.f()</error>);
|
||||
foo(c, x -> <error descr="Bad return type in lambda expression: A cannot be converted to C">x.f()</error>);
|
||||
foo(c, x -> x);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user