Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d0bf462

Browse files
committed
Kotlin: Add a copy of Java's controlflow/basic test
1 parent 715a92c commit d0bf462

13 files changed

Lines changed: 504 additions & 0 deletions
Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
package dominance;
2+
3+
public class Test {
4+
fun test() {
5+
var x: Int = 0
6+
var y: Long = 50
7+
var z: Int = 0
8+
var w: Int = 0
9+
10+
// if-else, multiple statements in block
11+
if (x > 0) {
12+
y = 20
13+
z = 10
14+
} else {
15+
y = 30
16+
}
17+
18+
z = 0
19+
20+
// if-else with return in one branch
21+
if(x < 0)
22+
y = 40
23+
else
24+
return
25+
26+
// this is not the start of a BB due to the return
27+
z = 10
28+
29+
// single-branch if-else
30+
if (x == 0) {
31+
y = 60
32+
z = 10
33+
}
34+
35+
z = 20
36+
37+
// while loop
38+
while(x > 0) {
39+
y = 10
40+
x--
41+
}
42+
43+
z = 30
44+
45+
/*
46+
TODO
47+
// for loop
48+
for(j in 0 .. 19) {
49+
y = 0
50+
w = 10
51+
}
52+
53+
z = 40
54+
55+
// nested control flow
56+
for(j in 0 .. 9) {
57+
y = 30
58+
if(z > 0)
59+
if(y > 0) {
60+
w = 0
61+
break;
62+
} else {
63+
w = 20
64+
}
65+
else {
66+
w = 10
67+
continue
68+
}
69+
x = 0
70+
}
71+
*/
72+
73+
z = 50
74+
75+
// nested control-flow
76+
77+
w = 40
78+
return
79+
}
80+
}
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
| Test.kt:3:1:80:1 | { ... } | 0 | Test.kt:3:1:80:1 | { ... } |
2+
| Test.kt:3:1:80:1 | { ... } | 0 | Test.kt:3:1:80:1 | { ... } |
3+
| Test.kt:3:1:80:1 | { ... } | 1 | Test.kt:3:1:80:1 | <obinit> |
4+
| Test.kt:3:1:80:1 | { ... } | 1 | Test.kt:3:1:80:1 | super(...) |
5+
| Test.kt:3:1:80:1 | { ... } | 2 | Test.kt:3:1:80:1 | <Expr>; |
6+
| Test.kt:3:1:80:1 | { ... } | 3 | Test.kt:3:1:80:1 | <obinit>(...) |
7+
| Test.kt:3:1:80:1 | { ... } | 4 | Test.kt:3:8:80:1 | Test |
8+
| Test.kt:4:2:79:2 | test | 0 | Test.kt:4:2:79:2 | test |
9+
| Test.kt:4:13:79:2 | { ... } | 0 | Test.kt:4:13:79:2 | { ... } |
10+
| Test.kt:4:13:79:2 | { ... } | 1 | Test.kt:5:3:5:16 | var ...; |
11+
| Test.kt:4:13:79:2 | { ... } | 2 | Test.kt:5:16:5:16 | 0 |
12+
| Test.kt:4:13:79:2 | { ... } | 3 | Test.kt:5:3:5:16 | x |
13+
| Test.kt:4:13:79:2 | { ... } | 4 | Test.kt:6:3:6:18 | var ...; |
14+
| Test.kt:4:13:79:2 | { ... } | 5 | Test.kt:6:17:6:18 | 50 |
15+
| Test.kt:4:13:79:2 | { ... } | 6 | Test.kt:6:3:6:18 | y |
16+
| Test.kt:4:13:79:2 | { ... } | 7 | Test.kt:7:3:7:16 | var ...; |
17+
| Test.kt:4:13:79:2 | { ... } | 8 | Test.kt:7:16:7:16 | 0 |
18+
| Test.kt:4:13:79:2 | { ... } | 9 | Test.kt:7:3:7:16 | z |
19+
| Test.kt:4:13:79:2 | { ... } | 10 | Test.kt:8:3:8:16 | var ...; |
20+
| Test.kt:4:13:79:2 | { ... } | 11 | Test.kt:8:16:8:16 | 0 |
21+
| Test.kt:4:13:79:2 | { ... } | 12 | Test.kt:8:3:8:16 | w |
22+
| Test.kt:4:13:79:2 | { ... } | 13 | Test.kt:11:3:16:3 | <Expr>; |
23+
| Test.kt:4:13:79:2 | { ... } | 14 | Test.kt:11:3:16:3 | when ... |
24+
| Test.kt:4:13:79:2 | { ... } | 15 | Test.kt:11:3:16:3 | ... -> ... |
25+
| Test.kt:4:13:79:2 | { ... } | 16 | Test.kt:11:7:11:7 | x |
26+
| Test.kt:4:13:79:2 | { ... } | 17 | Test.kt:11:11:11:11 | 0 |
27+
| Test.kt:4:13:79:2 | { ... } | 18 | Test.kt:11:7:11:11 | ... > ... |
28+
| Test.kt:11:3:16:3 | ... -> ... | 0 | Test.kt:11:3:16:3 | ... -> ... |
29+
| Test.kt:11:3:16:3 | ... -> ... | 1 | Test.kt:11:3:16:3 | true |
30+
| Test.kt:11:14:14:3 | { ... } | 0 | Test.kt:11:14:14:3 | { ... } |
31+
| Test.kt:11:14:14:3 | { ... } | 1 | Test.kt:12:4:12:4 | <Expr>; |
32+
| Test.kt:11:14:14:3 | { ... } | 2 | Test.kt:12:8:12:9 | 20 |
33+
| Test.kt:11:14:14:3 | { ... } | 3 | Test.kt:12:4:12:4 | ...=... |
34+
| Test.kt:11:14:14:3 | { ... } | 4 | Test.kt:13:4:13:4 | <Expr>; |
35+
| Test.kt:11:14:14:3 | { ... } | 5 | Test.kt:13:8:13:9 | 10 |
36+
| Test.kt:11:14:14:3 | { ... } | 6 | Test.kt:13:4:13:4 | ...=... |
37+
| Test.kt:14:10:16:3 | { ... } | 0 | Test.kt:14:10:16:3 | { ... } |
38+
| Test.kt:14:10:16:3 | { ... } | 1 | Test.kt:15:4:15:4 | <Expr>; |
39+
| Test.kt:14:10:16:3 | { ... } | 2 | Test.kt:15:8:15:9 | 30 |
40+
| Test.kt:14:10:16:3 | { ... } | 3 | Test.kt:15:4:15:4 | ...=... |
41+
| Test.kt:18:3:18:3 | <Expr>; | 0 | Test.kt:18:3:18:3 | <Expr>; |
42+
| Test.kt:18:3:18:3 | <Expr>; | 1 | Test.kt:18:7:18:7 | 0 |
43+
| Test.kt:18:3:18:3 | <Expr>; | 2 | Test.kt:18:3:18:3 | ...=... |
44+
| Test.kt:18:3:18:3 | <Expr>; | 3 | Test.kt:21:3:24:9 | <Expr>; |
45+
| Test.kt:18:3:18:3 | <Expr>; | 4 | Test.kt:21:3:24:9 | when ... |
46+
| Test.kt:18:3:18:3 | <Expr>; | 5 | Test.kt:21:3:24:9 | ... -> ... |
47+
| Test.kt:18:3:18:3 | <Expr>; | 6 | Test.kt:21:6:21:6 | x |
48+
| Test.kt:18:3:18:3 | <Expr>; | 7 | Test.kt:21:10:21:10 | 0 |
49+
| Test.kt:18:3:18:3 | <Expr>; | 8 | Test.kt:21:6:21:10 | ... < ... |
50+
| Test.kt:21:3:24:9 | ... -> ... | 0 | Test.kt:21:3:24:9 | ... -> ... |
51+
| Test.kt:21:3:24:9 | ... -> ... | 1 | Test.kt:21:3:24:9 | true |
52+
| Test.kt:22:4:22:4 | <Expr>; | 0 | Test.kt:22:4:22:4 | <Expr>; |
53+
| Test.kt:22:4:22:4 | <Expr>; | 1 | Test.kt:22:8:22:9 | 40 |
54+
| Test.kt:22:4:22:4 | <Expr>; | 2 | Test.kt:22:4:22:4 | ...=... |
55+
| Test.kt:22:4:22:4 | <Expr>; | 3 | Test.kt:27:3:27:3 | <Expr>; |
56+
| Test.kt:22:4:22:4 | <Expr>; | 4 | Test.kt:27:7:27:8 | 10 |
57+
| Test.kt:22:4:22:4 | <Expr>; | 5 | Test.kt:27:3:27:3 | ...=... |
58+
| Test.kt:22:4:22:4 | <Expr>; | 6 | Test.kt:30:3:33:3 | <Expr>; |
59+
| Test.kt:22:4:22:4 | <Expr>; | 7 | Test.kt:30:3:33:3 | when ... |
60+
| Test.kt:24:4:24:9 | return ... | 0 | Test.kt:24:4:24:9 | return ... |
61+
| Test.kt:30:3:33:3 | ... -> ... | 0 | Test.kt:30:3:33:3 | ... -> ... |
62+
| Test.kt:30:3:33:3 | ... -> ... | 1 | Test.kt:30:7:30:7 | x |
63+
| Test.kt:30:3:33:3 | ... -> ... | 2 | Test.kt:30:12:30:12 | 0 |
64+
| Test.kt:30:3:33:3 | ... -> ... | 3 | Test.kt:30:7:30:12 | ... == ... |
65+
| Test.kt:30:15:33:3 | { ... } | 0 | Test.kt:30:15:33:3 | { ... } |
66+
| Test.kt:30:15:33:3 | { ... } | 1 | Test.kt:31:4:31:4 | <Expr>; |
67+
| Test.kt:30:15:33:3 | { ... } | 2 | Test.kt:31:8:31:9 | 60 |
68+
| Test.kt:30:15:33:3 | { ... } | 3 | Test.kt:31:4:31:4 | ...=... |
69+
| Test.kt:30:15:33:3 | { ... } | 4 | Test.kt:32:4:32:4 | <Expr>; |
70+
| Test.kt:30:15:33:3 | { ... } | 5 | Test.kt:32:8:32:9 | 10 |
71+
| Test.kt:30:15:33:3 | { ... } | 6 | Test.kt:32:4:32:4 | ...=... |
72+
| Test.kt:35:3:35:3 | <Expr>; | 0 | Test.kt:35:3:35:3 | <Expr>; |
73+
| Test.kt:35:3:35:3 | <Expr>; | 1 | Test.kt:35:7:35:8 | 20 |
74+
| Test.kt:35:3:35:3 | <Expr>; | 2 | Test.kt:35:3:35:3 | ...=... |
75+
| Test.kt:35:3:35:3 | <Expr>; | 3 | Test.kt:38:3:41:3 | while (...) |
76+
| Test.kt:35:3:35:3 | <Expr>; | 4 | Test.kt:38:9:38:9 | x |
77+
| Test.kt:35:3:35:3 | <Expr>; | 5 | Test.kt:38:13:38:13 | 0 |
78+
| Test.kt:35:3:35:3 | <Expr>; | 6 | Test.kt:38:9:38:13 | ... > ... |
79+
| Test.kt:38:16:41:3 | { ... } | 0 | Test.kt:38:16:41:3 | { ... } |
80+
| Test.kt:38:16:41:3 | { ... } | 1 | Test.kt:39:4:39:4 | <Expr>; |
81+
| Test.kt:38:16:41:3 | { ... } | 2 | Test.kt:39:8:39:9 | 10 |
82+
| Test.kt:38:16:41:3 | { ... } | 3 | Test.kt:39:4:39:4 | ...=... |
83+
| Test.kt:38:16:41:3 | { ... } | 4 | Test.kt:40:4:40:6 | <Expr>; |
84+
| Test.kt:43:3:43:3 | <Expr>; | 0 | Test.kt:43:3:43:3 | <Expr>; |
85+
| Test.kt:43:3:43:3 | <Expr>; | 1 | Test.kt:43:7:43:8 | 30 |
86+
| Test.kt:43:3:43:3 | <Expr>; | 2 | Test.kt:43:3:43:3 | ...=... |
87+
| Test.kt:43:3:43:3 | <Expr>; | 3 | Test.kt:73:3:73:3 | <Expr>; |
88+
| Test.kt:43:3:43:3 | <Expr>; | 4 | Test.kt:73:7:73:8 | 50 |
89+
| Test.kt:43:3:43:3 | <Expr>; | 5 | Test.kt:73:3:73:3 | ...=... |
90+
| Test.kt:43:3:43:3 | <Expr>; | 6 | Test.kt:77:3:77:3 | <Expr>; |
91+
| Test.kt:43:3:43:3 | <Expr>; | 7 | Test.kt:77:7:77:8 | 40 |
92+
| Test.kt:43:3:43:3 | <Expr>; | 8 | Test.kt:77:3:77:3 | ...=... |
93+
| Test.kt:43:3:43:3 | <Expr>; | 9 | Test.kt:78:3:78:8 | return ... |
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import default
2+
3+
from BasicBlock b, int i, ControlFlowNode n
4+
where
5+
b.getNode(i) = n and
6+
b.getFile().(CompilationUnit).fromSource()
7+
select b, i, n

java/ql/test/kotlin/library-tests/controlflow/basic/bbStrictDominance.expected

Whitespace-only changes.
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import default
2+
import semmle.code.java.controlflow.Dominance
3+
4+
from BasicBlock b, BasicBlock b2
5+
where bbStrictlyDominates(b, b2)
6+
select b, b2
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
| Test.kt:11:14:14:3 | { ... } | Test.kt:18:3:18:3 | <Expr>; |
2+
| Test.kt:14:10:16:3 | { ... } | Test.kt:18:3:18:3 | <Expr>; |
3+
| Test.kt:22:4:22:4 | <Expr>; | Test.kt:30:3:33:3 | ... -> ... |
4+
| Test.kt:22:4:22:4 | <Expr>; | Test.kt:35:3:35:3 | <Expr>; |
5+
| Test.kt:24:4:24:9 | return ... | Test.kt:4:2:79:2 | test |
6+
| Test.kt:30:15:33:3 | { ... } | Test.kt:35:3:35:3 | <Expr>; |
7+
| Test.kt:35:3:35:3 | <Expr>; | Test.kt:38:16:41:3 | { ... } |
8+
| Test.kt:35:3:35:3 | <Expr>; | Test.kt:43:3:43:3 | <Expr>; |
9+
| Test.kt:43:3:43:3 | <Expr>; | Test.kt:4:2:79:2 | test |
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import default
2+
3+
from BasicBlock b, BasicBlock b2
4+
where b.getABBSuccessor() = b2
5+
select b, b2
Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
| Test.kt:3:1:80:1 | <Expr>; | ExprStmt | Test.kt:3:1:80:1 | <obinit>(...) | MethodAccess |
2+
| Test.kt:3:1:80:1 | <obinit> | Method | file://:0:0:0:0 | <none> | <none> |
3+
| Test.kt:3:1:80:1 | <obinit>(...) | MethodAccess | Test.kt:3:8:80:1 | Test | Constructor |
4+
| Test.kt:3:1:80:1 | Test | Class | file://:0:0:0:0 | <none> | <none> |
5+
| Test.kt:3:1:80:1 | super(...) | SuperConstructorInvocationStmt | Test.kt:3:1:80:1 | <Expr>; | ExprStmt |
6+
| Test.kt:3:1:80:1 | { ... } | BlockStmt | Test.kt:3:1:80:1 | <obinit> | Method |
7+
| Test.kt:3:1:80:1 | { ... } | BlockStmt | Test.kt:3:1:80:1 | super(...) | SuperConstructorInvocationStmt |
8+
| Test.kt:3:8:80:1 | Test | Constructor | file://:0:0:0:0 | <none> | <none> |
9+
| Test.kt:3:8:80:1 | equals | Method | file://:0:0:0:0 | <none> | <none> |
10+
| Test.kt:3:8:80:1 | hashCode | Method | file://:0:0:0:0 | <none> | <none> |
11+
| Test.kt:3:8:80:1 | other | Parameter | file://:0:0:0:0 | <none> | <none> |
12+
| Test.kt:3:8:80:1 | toString | Method | file://:0:0:0:0 | <none> | <none> |
13+
| Test.kt:4:2:79:2 | test | Method | file://:0:0:0:0 | <none> | <none> |
14+
| Test.kt:4:13:79:2 | { ... } | BlockStmt | Test.kt:5:3:5:16 | var ...; | LocalVariableDeclStmt |
15+
| Test.kt:5:3:5:16 | int x | LocalVariableDecl | file://:0:0:0:0 | <none> | <none> |
16+
| Test.kt:5:3:5:16 | var ...; | LocalVariableDeclStmt | Test.kt:5:16:5:16 | 0 | IntegerLiteral |
17+
| Test.kt:5:3:5:16 | x | LocalVariableDeclExpr | Test.kt:6:3:6:18 | var ...; | LocalVariableDeclStmt |
18+
| Test.kt:5:16:5:16 | 0 | IntegerLiteral | Test.kt:5:3:5:16 | x | LocalVariableDeclExpr |
19+
| Test.kt:6:3:6:18 | long y | LocalVariableDecl | file://:0:0:0:0 | <none> | <none> |
20+
| Test.kt:6:3:6:18 | var ...; | LocalVariableDeclStmt | Test.kt:6:17:6:18 | 50 | LongLiteral |
21+
| Test.kt:6:3:6:18 | y | LocalVariableDeclExpr | Test.kt:7:3:7:16 | var ...; | LocalVariableDeclStmt |
22+
| Test.kt:6:17:6:18 | 50 | LongLiteral | Test.kt:6:3:6:18 | y | LocalVariableDeclExpr |
23+
| Test.kt:7:3:7:16 | int z | LocalVariableDecl | file://:0:0:0:0 | <none> | <none> |
24+
| Test.kt:7:3:7:16 | var ...; | LocalVariableDeclStmt | Test.kt:7:16:7:16 | 0 | IntegerLiteral |
25+
| Test.kt:7:3:7:16 | z | LocalVariableDeclExpr | Test.kt:8:3:8:16 | var ...; | LocalVariableDeclStmt |
26+
| Test.kt:7:16:7:16 | 0 | IntegerLiteral | Test.kt:7:3:7:16 | z | LocalVariableDeclExpr |
27+
| Test.kt:8:3:8:16 | int w | LocalVariableDecl | file://:0:0:0:0 | <none> | <none> |
28+
| Test.kt:8:3:8:16 | var ...; | LocalVariableDeclStmt | Test.kt:8:16:8:16 | 0 | IntegerLiteral |
29+
| Test.kt:8:3:8:16 | w | LocalVariableDeclExpr | Test.kt:11:3:16:3 | <Expr>; | ExprStmt |
30+
| Test.kt:8:16:8:16 | 0 | IntegerLiteral | Test.kt:8:3:8:16 | w | LocalVariableDeclExpr |
31+
| Test.kt:11:3:16:3 | ... -> ... | WhenBranch | Test.kt:11:3:16:3 | true | BooleanLiteral |
32+
| Test.kt:11:3:16:3 | ... -> ... | WhenBranch | Test.kt:11:7:11:7 | x | VarAccess |
33+
| Test.kt:11:3:16:3 | <Expr>; | ExprStmt | Test.kt:11:3:16:3 | when ... | WhenExpr |
34+
| Test.kt:11:3:16:3 | true | BooleanLiteral | file://:0:0:0:0 | <none> | <none> |
35+
| Test.kt:11:3:16:3 | when ... | WhenExpr | Test.kt:11:3:16:3 | ... -> ... | WhenBranch |
36+
| Test.kt:11:7:11:7 | x | VarAccess | Test.kt:11:11:11:11 | 0 | IntegerLiteral |
37+
| Test.kt:11:7:11:11 | ... > ... | GTExpr | file://:0:0:0:0 | <none> | <none> |
38+
| Test.kt:11:11:11:11 | 0 | IntegerLiteral | Test.kt:11:7:11:11 | ... > ... | GTExpr |
39+
| Test.kt:11:14:14:3 | { ... } | BlockStmt | Test.kt:12:4:12:4 | <Expr>; | ExprStmt |
40+
| Test.kt:12:4:12:4 | ...=... | AssignExpr | Test.kt:13:4:13:4 | <Expr>; | ExprStmt |
41+
| Test.kt:12:4:12:4 | <Expr>; | ExprStmt | Test.kt:12:8:12:9 | 20 | LongLiteral |
42+
| Test.kt:12:8:12:9 | 20 | LongLiteral | Test.kt:12:4:12:4 | ...=... | AssignExpr |
43+
| Test.kt:13:4:13:4 | ...=... | AssignExpr | Test.kt:18:3:18:3 | <Expr>; | ExprStmt |
44+
| Test.kt:13:4:13:4 | <Expr>; | ExprStmt | Test.kt:13:8:13:9 | 10 | IntegerLiteral |
45+
| Test.kt:13:8:13:9 | 10 | IntegerLiteral | Test.kt:13:4:13:4 | ...=... | AssignExpr |
46+
| Test.kt:14:10:16:3 | { ... } | BlockStmt | Test.kt:15:4:15:4 | <Expr>; | ExprStmt |
47+
| Test.kt:15:4:15:4 | ...=... | AssignExpr | Test.kt:18:3:18:3 | <Expr>; | ExprStmt |
48+
| Test.kt:15:4:15:4 | <Expr>; | ExprStmt | Test.kt:15:8:15:9 | 30 | LongLiteral |
49+
| Test.kt:15:8:15:9 | 30 | LongLiteral | Test.kt:15:4:15:4 | ...=... | AssignExpr |
50+
| Test.kt:18:3:18:3 | ...=... | AssignExpr | Test.kt:21:3:24:9 | <Expr>; | ExprStmt |
51+
| Test.kt:18:3:18:3 | <Expr>; | ExprStmt | Test.kt:18:7:18:7 | 0 | IntegerLiteral |
52+
| Test.kt:18:7:18:7 | 0 | IntegerLiteral | Test.kt:18:3:18:3 | ...=... | AssignExpr |
53+
| Test.kt:21:3:24:9 | ... -> ... | WhenBranch | Test.kt:21:3:24:9 | true | BooleanLiteral |
54+
| Test.kt:21:3:24:9 | ... -> ... | WhenBranch | Test.kt:21:6:21:6 | x | VarAccess |
55+
| Test.kt:21:3:24:9 | <Expr>; | ExprStmt | Test.kt:21:3:24:9 | when ... | WhenExpr |
56+
| Test.kt:21:3:24:9 | true | BooleanLiteral | file://:0:0:0:0 | <none> | <none> |
57+
| Test.kt:21:3:24:9 | when ... | WhenExpr | Test.kt:21:3:24:9 | ... -> ... | WhenBranch |
58+
| Test.kt:21:6:21:6 | x | VarAccess | Test.kt:21:10:21:10 | 0 | IntegerLiteral |
59+
| Test.kt:21:6:21:10 | ... < ... | LTExpr | file://:0:0:0:0 | <none> | <none> |
60+
| Test.kt:21:10:21:10 | 0 | IntegerLiteral | Test.kt:21:6:21:10 | ... < ... | LTExpr |
61+
| Test.kt:22:4:22:4 | ...=... | AssignExpr | Test.kt:27:3:27:3 | <Expr>; | ExprStmt |
62+
| Test.kt:22:4:22:4 | <Expr>; | ExprStmt | Test.kt:22:8:22:9 | 40 | LongLiteral |
63+
| Test.kt:22:8:22:9 | 40 | LongLiteral | Test.kt:22:4:22:4 | ...=... | AssignExpr |
64+
| Test.kt:24:4:24:9 | return ... | ReturnStmt | Test.kt:4:2:79:2 | test | Method |
65+
| Test.kt:27:3:27:3 | ...=... | AssignExpr | Test.kt:30:3:33:3 | <Expr>; | ExprStmt |
66+
| Test.kt:27:3:27:3 | <Expr>; | ExprStmt | Test.kt:27:7:27:8 | 10 | IntegerLiteral |
67+
| Test.kt:27:7:27:8 | 10 | IntegerLiteral | Test.kt:27:3:27:3 | ...=... | AssignExpr |
68+
| Test.kt:30:3:33:3 | ... -> ... | WhenBranch | Test.kt:30:7:30:7 | x | VarAccess |
69+
| Test.kt:30:3:33:3 | <Expr>; | ExprStmt | Test.kt:30:3:33:3 | when ... | WhenExpr |
70+
| Test.kt:30:3:33:3 | when ... | WhenExpr | Test.kt:30:3:33:3 | ... -> ... | WhenBranch |
71+
| Test.kt:30:3:33:3 | when ... | WhenExpr | Test.kt:35:3:35:3 | <Expr>; | ExprStmt |
72+
| Test.kt:30:7:30:7 | x | VarAccess | Test.kt:30:12:30:12 | 0 | IntegerLiteral |
73+
| Test.kt:30:7:30:12 | ... == ... | EQExpr | file://:0:0:0:0 | <none> | <none> |
74+
| Test.kt:30:12:30:12 | 0 | IntegerLiteral | Test.kt:30:7:30:12 | ... == ... | EQExpr |
75+
| Test.kt:30:15:33:3 | { ... } | BlockStmt | Test.kt:31:4:31:4 | <Expr>; | ExprStmt |
76+
| Test.kt:31:4:31:4 | ...=... | AssignExpr | Test.kt:32:4:32:4 | <Expr>; | ExprStmt |
77+
| Test.kt:31:4:31:4 | <Expr>; | ExprStmt | Test.kt:31:8:31:9 | 60 | LongLiteral |
78+
| Test.kt:31:8:31:9 | 60 | LongLiteral | Test.kt:31:4:31:4 | ...=... | AssignExpr |
79+
| Test.kt:32:4:32:4 | ...=... | AssignExpr | Test.kt:35:3:35:3 | <Expr>; | ExprStmt |
80+
| Test.kt:32:4:32:4 | <Expr>; | ExprStmt | Test.kt:32:8:32:9 | 10 | IntegerLiteral |
81+
| Test.kt:32:8:32:9 | 10 | IntegerLiteral | Test.kt:32:4:32:4 | ...=... | AssignExpr |
82+
| Test.kt:35:3:35:3 | ...=... | AssignExpr | Test.kt:38:3:41:3 | while (...) | WhileStmt |
83+
| Test.kt:35:3:35:3 | <Expr>; | ExprStmt | Test.kt:35:7:35:8 | 20 | IntegerLiteral |
84+
| Test.kt:35:7:35:8 | 20 | IntegerLiteral | Test.kt:35:3:35:3 | ...=... | AssignExpr |
85+
| Test.kt:38:3:41:3 | while (...) | WhileStmt | Test.kt:38:9:38:9 | x | VarAccess |
86+
| Test.kt:38:9:38:9 | x | VarAccess | Test.kt:38:13:38:13 | 0 | IntegerLiteral |
87+
| Test.kt:38:9:38:13 | ... > ... | GTExpr | Test.kt:38:16:41:3 | { ... } | BlockStmt |
88+
| Test.kt:38:9:38:13 | ... > ... | GTExpr | Test.kt:43:3:43:3 | <Expr>; | ExprStmt |
89+
| Test.kt:38:13:38:13 | 0 | IntegerLiteral | Test.kt:38:9:38:13 | ... > ... | GTExpr |
90+
| Test.kt:38:16:41:3 | { ... } | BlockStmt | Test.kt:39:4:39:4 | <Expr>; | ExprStmt |
91+
| Test.kt:39:4:39:4 | ...=... | AssignExpr | Test.kt:40:4:40:6 | <Expr>; | ExprStmt |
92+
| Test.kt:39:4:39:4 | <Expr>; | ExprStmt | Test.kt:39:8:39:9 | 10 | LongLiteral |
93+
| Test.kt:39:8:39:9 | 10 | LongLiteral | Test.kt:39:4:39:4 | ...=... | AssignExpr |
94+
| Test.kt:40:4:40:6 | <Expr>; | ExprStmt | file://:0:0:0:0 | <none> | <none> |
95+
| Test.kt:43:3:43:3 | ...=... | AssignExpr | Test.kt:73:3:73:3 | <Expr>; | ExprStmt |
96+
| Test.kt:43:3:43:3 | <Expr>; | ExprStmt | Test.kt:43:7:43:8 | 30 | IntegerLiteral |
97+
| Test.kt:43:7:43:8 | 30 | IntegerLiteral | Test.kt:43:3:43:3 | ...=... | AssignExpr |
98+
| Test.kt:73:3:73:3 | ...=... | AssignExpr | Test.kt:77:3:77:3 | <Expr>; | ExprStmt |
99+
| Test.kt:73:3:73:3 | <Expr>; | ExprStmt | Test.kt:73:7:73:8 | 50 | IntegerLiteral |
100+
| Test.kt:73:7:73:8 | 50 | IntegerLiteral | Test.kt:73:3:73:3 | ...=... | AssignExpr |
101+
| Test.kt:77:3:77:3 | ...=... | AssignExpr | Test.kt:78:3:78:8 | return ... | ReturnStmt |
102+
| Test.kt:77:3:77:3 | <Expr>; | ExprStmt | Test.kt:77:7:77:8 | 40 | IntegerLiteral |
103+
| Test.kt:77:7:77:8 | 40 | IntegerLiteral | Test.kt:77:3:77:3 | ...=... | AssignExpr |
104+
| Test.kt:78:3:78:8 | return ... | ReturnStmt | Test.kt:4:2:79:2 | test | Method |
105+
| file://:0:0:0:0 | Any | Class | file://:0:0:0:0 | <none> | <none> |
106+
| file://:0:0:0:0 | Any | Constructor | file://:0:0:0:0 | <none> | <none> |
107+
| file://:0:0:0:0 | Boolean | Class | file://:0:0:0:0 | <none> | <none> |
108+
| file://:0:0:0:0 | Int | Class | file://:0:0:0:0 | <none> | <none> |
109+
| file://:0:0:0:0 | Long | Class | file://:0:0:0:0 | <none> | <none> |
110+
| file://:0:0:0:0 | String | Class | file://:0:0:0:0 | <none> | <none> |
111+
| file://:0:0:0:0 | String | Class | file://:0:0:0:0 | <none> | <none> |
112+
| file://:0:0:0:0 | Unit | Class | file://:0:0:0:0 | <none> | <none> |
113+
| file://:0:0:0:0 | equals | Method | file://:0:0:0:0 | <none> | <none> |
114+
| file://:0:0:0:0 | equals | Method | file://:0:0:0:0 | <none> | <none> |
115+
| file://:0:0:0:0 | hashCode | Method | file://:0:0:0:0 | <none> | <none> |
116+
| file://:0:0:0:0 | hashCode | Method | file://:0:0:0:0 | <none> | <none> |
117+
| file://:0:0:0:0 | other | Parameter | file://:0:0:0:0 | <none> | <none> |
118+
| file://:0:0:0:0 | other | Parameter | file://:0:0:0:0 | <none> | <none> |
119+
| file://:0:0:0:0 | toString | Method | file://:0:0:0:0 | <none> | <none> |
120+
| file://:0:0:0:0 | toString | Method | file://:0:0:0:0 | <none> | <none> |
121+
| file://:0:0:0:0 | w | VarAccess | file://:0:0:0:0 | <none> | <none> |
122+
| file://:0:0:0:0 | y | VarAccess | file://:0:0:0:0 | <none> | <none> |
123+
| file://:0:0:0:0 | y | VarAccess | file://:0:0:0:0 | <none> | <none> |
124+
| file://:0:0:0:0 | y | VarAccess | file://:0:0:0:0 | <none> | <none> |
125+
| file://:0:0:0:0 | y | VarAccess | file://:0:0:0:0 | <none> | <none> |
126+
| file://:0:0:0:0 | y | VarAccess | file://:0:0:0:0 | <none> | <none> |
127+
| file://:0:0:0:0 | z | VarAccess | file://:0:0:0:0 | <none> | <none> |
128+
| file://:0:0:0:0 | z | VarAccess | file://:0:0:0:0 | <none> | <none> |
129+
| file://:0:0:0:0 | z | VarAccess | file://:0:0:0:0 | <none> | <none> |
130+
| file://:0:0:0:0 | z | VarAccess | file://:0:0:0:0 | <none> | <none> |
131+
| file://:0:0:0:0 | z | VarAccess | file://:0:0:0:0 | <none> | <none> |
132+
| file://:0:0:0:0 | z | VarAccess | file://:0:0:0:0 | <none> | <none> |
133+
| file://:0:0:0:0 | z | VarAccess | file://:0:0:0:0 | <none> | <none> |

0 commit comments

Comments
 (0)