File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
lib/codeql/rust/elements/internal
test/library-tests/elements/stmtlist Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ module Impl {
3333 AstNode getStmtOrExpr ( int index ) {
3434 result = this .getStatement ( index )
3535 or
36- index = max ( int i | exists ( this .getStatement ( i ) ) ) + 1 and
36+ index = max ( int i | i = - 1 or exists ( this .getStatement ( i ) ) ) + 1 and
3737 result = this .getTailExpr ( )
3838 }
3939
Original file line number Diff line number Diff line change 11| StmtList.rs:4:19:9:1 | StmtList | 2 | hasTailExpr | 0:let ... = 1, 1:let ... = 2, 2:... + ... |
22| StmtList.rs:11:18:15:1 | StmtList | 2 | | 0:let ... = 1, 1:let ... = 2 |
3- | StmtList.rs:17:19:20:1 | StmtList | 0 | hasTailExpr | |
3+ | StmtList.rs:17:19:20:1 | StmtList | 0 | hasTailExpr | 0:... + ... |
44| StmtList.rs:22:18:25:1 | StmtList | 1 | | 0:ExprStmt |
55| StmtList.rs:27:18:29:1 | StmtList | 0 | | |
66| StmtList.rs:31:18:34:1 | StmtList | 0 | | |
7- | StmtList.rs:36:29:43:1 | StmtList | 0 | hasTailExpr | |
8- | StmtList.rs:38:10:40:2 | StmtList | 0 | hasTailExpr | |
9- | StmtList.rs:40:9:42:2 | StmtList | 0 | hasTailExpr | |
7+ | StmtList.rs:36:29:43:1 | StmtList | 0 | hasTailExpr | 0:if cond {...} else {...} |
8+ | StmtList.rs:38:10:40:2 | StmtList | 0 | hasTailExpr | 0:1 |
9+ | StmtList.rs:40:9:42:2 | StmtList | 0 | hasTailExpr | 0:2 |
You can’t perform that action at this time.
0 commit comments