File tree Expand file tree Collapse file tree 4 files changed +43
-0
lines changed
java/ql/test/kotlin/library-tests/private-anonymous-types Expand file tree Collapse file tree 4 files changed +43
-0
lines changed Original file line number Diff line number Diff line change 1+ class Ext : A <String >(" Hello" ) { }
Original file line number Diff line number Diff line change 1+ | file:///!unknown-binary-location/A.class:0:0:0:0 | A<String> | file:///!unknown-binary-location/A.class:0:0:0:0 | A<String> |
2+ | file:///!unknown-binary-location/A.class:0:0:0:0 | A<String> | file:///!unknown-binary-location/A.class:0:0:0:0 | getAnonType |
3+ | file:///!unknown-binary-location/If.class:0:0:0:0 | If<String> | file:///!unknown-binary-location/If.class:0:0:0:0 | getX |
4+ | file:///!unknown-binary-location/If.class:0:0:0:0 | If<T> | file:///!unknown-binary-location/If.class:0:0:0:0 | getX |
5+ | other.kt:1:1:1:34 | Ext | other.kt:1:1:1:34 | Ext |
6+ | test.kt:0:0:0:0 | TestKt | test.kt:19:1:19:38 | user |
7+ | test.kt:1:1:5:1 | If | test.kt:3:3:3:11 | getX |
8+ | test.kt:7:1:17:1 | A | test.kt:7:6:17:1 | A |
9+ | test.kt:7:1:17:1 | A | test.kt:9:3:11:3 | anonType |
10+ | test.kt:7:1:17:1 | A | test.kt:9:3:11:3 | getAnonType |
11+ | test.kt:7:1:17:1 | A | test.kt:13:3:15:3 | privateAnonType |
12+ | test.kt:7:1:17:1 | A | test.kt:13:11:15:3 | getPrivateAnonType |
13+ | test.kt:9:18:11:3 | new If<T>(...) { ... } | test.kt:9:18:11:3 | |
14+ | test.kt:9:18:11:3 | new If<T>(...) { ... } | test.kt:10:5:10:22 | x |
15+ | test.kt:9:18:11:3 | new If<T>(...) { ... } | test.kt:10:14:10:22 | getX |
16+ | test.kt:13:33:15:3 | new If<T>(...) { ... } | test.kt:13:33:15:3 | |
17+ | test.kt:13:33:15:3 | new If<T>(...) { ... } | test.kt:14:5:14:22 | x |
18+ | test.kt:13:33:15:3 | new If<T>(...) { ... } | test.kt:14:14:14:22 | getX |
Original file line number Diff line number Diff line change 1+ interface If <T > {
2+
3+ val x : T
4+
5+ }
6+
7+ open class A <T >(t : T ) {
8+
9+ val anonType = object : If <T > {
10+ override val x = t
11+ }
12+
13+ private val privateAnonType = object : If <T > {
14+ override val x = t
15+ }
16+
17+ }
18+
19+ fun user (x : A <String >) = x.anonType.x
Original file line number Diff line number Diff line change 1+ import java
2+
3+ from ClassOrInterface ci , Member m
4+ where m = ci .getAMember ( ) and ci .getSourceDeclaration ( ) .fromSource ( )
5+ select ci , m
You can’t perform that action at this time.
0 commit comments