Skip to content

Commit

Permalink
More StmtParent -> SwitchBlock
Browse files Browse the repository at this point in the history
  • Loading branch information
smowton committed Nov 30, 2023
1 parent e93fe8d commit 94819e3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion java/ql/lib/semmle/code/java/Expr.qll
Original file line number Diff line number Diff line change
Expand Up @@ -1684,7 +1684,7 @@ class LocalVariableDeclExpr extends Expr, @localvariabledeclexpr {
/**
* Gets the switch statement or expression whose pattern declares this identifier, if any.
*/
StmtParent getAssociatedSwitch() {
SwitchBlock getAssociatedSwitch() {
exists(PatternCase pc |
pc = result.(SwitchStmt).getAPatternCase()
or
Expand Down
2 changes: 1 addition & 1 deletion java/ql/lib/semmle/code/java/Statement.qll
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ class SwitchCase extends Stmt, @case {
* Holds if this is the `n`th case of switch block `parent`.
*/
pragma[nomagic]
predicate isNthCaseOf(StmtParent parent, int n) {
predicate isNthCaseOf(SwitchBlock parent, int n) {
this.getCaseIndex() = n and this.getParent() = parent
}

Expand Down

0 comments on commit 94819e3

Please sign in to comment.