mirror of
https://github.com/github/codeql.git
synced 2026-03-23 16:06:47 +01:00
12 lines
305 B
Plaintext
12 lines
305 B
Plaintext
/**
|
|
* @name Test for try catches
|
|
*/
|
|
import csharp
|
|
|
|
from Method m, TryStmt s, GeneralCatchClause c
|
|
where s.getEnclosingCallable() = m
|
|
and m.getName() = "MainTryThrow"
|
|
and s.getCatchClause(1) = c
|
|
and c.getCaughtExceptionType().getName() = "Exception"
|
|
select c, c.getCaughtExceptionType().toString()
|