CodeQL library for C/C++
codeql/cpp-all 0.12.10 (changelog, source)
Search

Member predicate SwitchCase::getSwitchStmt

Gets the ‘switch’ statement of this ‘switch case’ statement.

For example, with

switch(i) {
case 5:
    x = 1;
}

the result of this predicate on case 5: is the whole switch(i) { ... } statement.

SwitchStmt getSwitchStmt()