mirror of
https://github.com/github/codeql.git
synced 2025-12-17 01:03:14 +01:00
Update java/ql/lib/semmle/code/java/ControlFlowGraph.qll
Co-authored-by: Tom Hvitved <hvitved@github.com>
This commit is contained in:
committed by
GitHub
parent
d0d47808e9
commit
6131c680f6
@@ -1123,9 +1123,12 @@ private module ControlFlowGraphImpl {
|
||||
or
|
||||
// `assert` statements may throw
|
||||
completion = ThrowCompletion(assertionError()) and
|
||||
if exists(assertstmt.getMessage())
|
||||
then last(assertstmt.getMessage(), last, NormalCompletion())
|
||||
else last(assertstmt.getExpr(), last, BooleanCompletion(false, _))
|
||||
(
|
||||
last(assertstmt.getMessage(), last, NormalCompletion())
|
||||
or
|
||||
not exists(assertstmt.getMessage()) and
|
||||
last(assertstmt.getExpr(), last, BooleanCompletion(false, _))
|
||||
)
|
||||
)
|
||||
or
|
||||
// `throw` statements or throwing calls give rise to `Throw` completion
|
||||
|
||||
Reference in New Issue
Block a user