mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-26 03:13:40 +07:00
add exception to throws: find functional interface method for method references; discard if in library (IDEA-134468)
This commit is contained in:
+14
@@ -0,0 +1,14 @@
|
||||
// "Add exception to method signature" "true"
|
||||
class C {
|
||||
public static void main(String[] args){
|
||||
I i = C::foo;
|
||||
}
|
||||
|
||||
class Ex extends Exception {}
|
||||
|
||||
static void foo() throws Ex {}
|
||||
|
||||
interface I {
|
||||
void f() throws Ex;
|
||||
}
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
// "Add exception to method signature" "true"
|
||||
class C {
|
||||
public static void main(String[] args){
|
||||
I i = C::f<caret>oo;
|
||||
}
|
||||
|
||||
class Ex extends Exception {}
|
||||
|
||||
static void foo() throws Ex {}
|
||||
|
||||
interface I {
|
||||
void f();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user