mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-12 00:21:32 +00:00
Improve heuristic to decide whether we will generate DefaultImpls for interface
This is not accurate, there are some cases when we will generate DefaultImpls class that are not covered: - Inherited default implementations - Annotated members In these cases IDE will report an error when in fact code compiles What is critical though is to be able to decide whether to build DefaultImpls light classes solely based on psi without triggering stubs calculation
This commit is contained in:
13
idea/testData/kotlinAndJavaChecker/javaAgainstKotlin/InterfaceDefaultImpls.java
vendored
Normal file
13
idea/testData/kotlinAndJavaChecker/javaAgainstKotlin/InterfaceDefaultImpls.java
vendored
Normal file
@@ -0,0 +1,13 @@
|
||||
import lib.*;
|
||||
|
||||
class C {
|
||||
public static void test(NonAbstractFun i, NonAbstractFunWithExpressionBody i2, NonAbstractProperty i3, NonAbstractPropertyWithBody i4) {
|
||||
AllAbstract.<error descr="Cannot resolve symbol 'DefaultImpls'">DefaultImpls</error>;
|
||||
|
||||
NonAbstractFun.DefaultImpls.f(i);
|
||||
NonAbstractFunWithExpressionBody.DefaultImpls.f(i2);
|
||||
|
||||
NonAbstractProperty.DefaultImpls.getC(i3);
|
||||
NonAbstractPropertyWithBody.DefaultImpls.getC(i4);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user