IDEA-123839: abstract&default combination

This commit is contained in:
Anna Kozlova
2014-04-11 17:02:36 +02:00
parent 75f267c222
commit 0d66941866
4 changed files with 20 additions and 6 deletions

View File

@@ -0,0 +1,13 @@
import java.util.Iterator;
interface A4 {
default Iterator iterator() {
return null;
}
}
interface A5 {
Iterator iterator();
}
abstract class <error descr="B inherits unrelated defaults for iterator() from types A5 and A4">B</error> implements A5, A4 {}

View File

@@ -12,7 +12,7 @@ interface SecondParent {
class <error descr="Class 'SecondParent' must either be declared abstract or implement abstract method 'doSomething()' in 'SecondParent'">FirstSon</error> implements FirstParent, SecondParent {}
<error descr="Class 'SecondSon' must either be declared abstract or implement abstract method 'doSomething()' in 'SecondParent'">class SecondSon implements SecondParent, FirstParent</error> {}
<error descr="Class 'SecondSon' must either be declared abstract or implement abstract method 'doSomething()' in 'SecondParent'">class <error descr="SecondSon inherits unrelated defaults for doSomething() from types SecondParent and FirstParent">SecondSon</error> implements SecondParent, FirstParent</error> {}
interface A {
default int foo() {