File tree Expand file tree Collapse file tree 2 files changed +1
-3
lines changed
java/ql/lib/semmle/code/java
shared/controlflow/codeql/controlflow Expand file tree Collapse file tree 2 files changed +1
-3
lines changed Original file line number Diff line number Diff line change @@ -165,8 +165,6 @@ private module Ast implements AstSig<Location> {
165165
166166 class DefaultCase extends Case instanceof J:: DefaultCase { }
167167
168- predicate fallsThrough ( Case c ) { not c .( J:: SwitchCase ) .isRule ( ) }
169-
170168 class ConditionalExpr = J:: ConditionalExpr ;
171169
172170 class BinaryExpr = J:: BinaryExpr ;
Original file line number Diff line number Diff line change @@ -261,7 +261,7 @@ signature module AstSig<LocationSig Location> {
261261 * Holds if this case can fall through to the next case if it is not
262262 * otherwise prevented with a `break` or similar.
263263 */
264- default predicate fallsThrough ( Case c ) { none ( ) }
264+ default predicate fallsThrough ( Case c ) { not exists ( c . getBody ( ) ) }
265265
266266 /** A ternary conditional expression. */
267267 class ConditionalExpr extends Expr {
You can’t perform that action at this time.
0 commit comments