Rust: Fix multiple CFG successors in range pattern without lower bound

This commit is contained in:
Simon Friis Vindum
2024-10-18 10:07:35 +02:00
parent b0625f83c6
commit 7aa28a0449
2 changed files with 1 additions and 2 deletions

View File

@@ -612,7 +612,7 @@ module PatternTrees {
result = rank[i + 1](Pat pat, int j | pat = this.getPat(j) | pat order by j)
}
predicate isEmpty() { not any(Pat p) = this.getPat(0) }
predicate isEmpty() { not any(Pat p) = this.getPatRanked(0) }
override predicate propagatesAbnormal(AstNode child) { child = this.getPatRanked(_) }

View File

@@ -716,7 +716,6 @@ edges
| test.rs:335:9:340:9 | MatchExpr | test.rs:334:31:341:5 | BlockExpr | |
| test.rs:335:15:335:16 | 42 | test.rs:336:13:336:15 | RangePat | |
| test.rs:336:13:336:15 | RangePat | test.rs:336:15:336:15 | LiteralPat | match |
| test.rs:336:13:336:15 | RangePat | test.rs:336:20:336:20 | 1 | match |
| test.rs:336:13:336:15 | RangePat | test.rs:337:13:337:16 | RangePat | no-match |
| test.rs:336:15:336:15 | LiteralPat | test.rs:336:20:336:20 | 1 | match |
| test.rs:336:15:336:15 | LiteralPat | test.rs:337:13:337:16 | RangePat | no-match |