mirror of
https://github.com/github/codeql.git
synced 2026-03-30 20:28:15 +02:00
Cfg: Update fallsThrough default.
This commit is contained in:
@@ -165,8 +165,6 @@ private module Ast implements AstSig<Location> {
|
||||
|
||||
class DefaultCase extends Case instanceof J::DefaultCase { }
|
||||
|
||||
predicate fallsThrough(Case c) { not c.(J::SwitchCase).isRule() }
|
||||
|
||||
class ConditionalExpr = J::ConditionalExpr;
|
||||
|
||||
class BinaryExpr = J::BinaryExpr;
|
||||
|
||||
@@ -261,7 +261,7 @@ signature module AstSig<LocationSig Location> {
|
||||
* Holds if this case can fall through to the next case if it is not
|
||||
* otherwise prevented with a `break` or similar.
|
||||
*/
|
||||
default predicate fallsThrough(Case c) { none() }
|
||||
default predicate fallsThrough(Case c) { not exists(c.getBody()) }
|
||||
|
||||
/** A ternary conditional expression. */
|
||||
class ConditionalExpr extends Expr {
|
||||
|
||||
Reference in New Issue
Block a user