Apply suggestions from code review

Co-authored-by: Geoffrey White <40627776+geoffw0@users.noreply.github.com>
This commit is contained in:
ihsinme
2021-07-14 10:11:28 +03:00
committed by GitHub
parent 6e7644f529
commit 1e12ede9fa
2 changed files with 2 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
...
throw ("my exception!",546); // BBAD
throw ("my exception!",546); // BAD
...
throw errorFunc("my exception!",546); // GOOD
...

View File

@@ -24,7 +24,7 @@ where
texp.getEnclosingStmt().getParentStmt*() = ts.getStmt() and
not ts.getACatchClause().isEmpty()
) and
msg = "DllMain contains exeption no wrapped to try..catch blocks."
msg = "DllMain contains an exeption not wrapped in a try..catch block."
or
texp.getExpr().isParenthesised() and
texp.getExpr().(CommaExpr).getLeftOperand().isConstant() and