Open
Description
package p1;
public class Test {
@FunctionalInterface
public static interface A {
String foo();
}
@FunctionalInterface
public static interface B extends A {
default String bar() { return bar(); };
String foo();
}
@FunctionalInterface
public static interface C extends B {
@Override String bar();
default String foo() { return "C"; }
}
}
scala> println(samOf(typeOf[p1.Test.C]))
<none>
It isn't clear to me that the current approach of treating Java default methods as concrete from the perspective of the Scala type system is the right approach. (We already have a different mechanism to mark them: Flag.JAVA_DEFAULT_METHOD
), which we can use in override checks, etc.