Skip to content

Commit b2452cd

Browse files
committed
Add test
1 parent 9ba8854 commit b2452cd

File tree

2 files changed

+23
-0
lines changed

2 files changed

+23
-0
lines changed

tests/pos/i24074/JavaPart.java

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
public class JavaPart {
2+
public interface A { }
3+
public interface B extends A {
4+
int onlyInB();
5+
}
6+
7+
public interface Lvl1 {
8+
A[] getData();
9+
}
10+
11+
public interface Lvl2 extends Lvl1 {
12+
@Override
13+
B[] getData();
14+
}
15+
16+
public interface Lvl3 extends Lvl2, Lvl1 { }
17+
}

tests/pos/i24074/Test.scala

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
// trait Test extends JavaPart.Lvl3
2+
// object TestImpl extends Test:
3+
// def getData(): Array[JavaPart.B] = ???
4+
object Test:
5+
def test(lvl3: JavaPart.Lvl3): Unit =
6+
lvl3.getData.head.onlyInB()

0 commit comments

Comments
 (0)