KT-2069 Cannot call super method when superclass has type parameters

#KT-2069 fixed
This commit is contained in:
Svetlana Isakova
2012-06-04 18:56:01 +04:00
parent 84a3974460
commit 0cd8534230
2 changed files with 18 additions and 3 deletions
@@ -473,10 +473,11 @@ public class WritableScopeImpl extends WritableScopeWithImports {
public void getImplicitReceiversHierarchy(@NotNull List<ReceiverDescriptor> result) {
checkMayRead();
if (implicitReceiver != null && implicitReceiver.exists()) {
result.add(implicitReceiver);
}
super.getImplicitReceiversHierarchy(result);
if (implicitReceiver != null && implicitReceiver.exists()) {
result.add(0, implicitReceiver);
}
}
// @SuppressWarnings({"NullableProblems"})
@@ -0,0 +1,14 @@
//KT-2069 Cannot call super method when superclass has type parameters
package kt2069
trait T1 {
fun foo() {}
}
class T : T1 {
fun bar() {
super<T1>.foo()
}
class object {}
}