Files
codeql/csharp/ql/test/library-tests/expressions/Is1.ql
2018-12-20 10:19:59 +01:00

14 lines
301 B
Plaintext

/**
* @name Test for is expressions
*/
import csharp
from Method m, IsTypeExpr e
where
m.hasName("MainIsAsCast") and
e.getEnclosingCallable() = m and
e.getExpr().(ParameterAccess).getTarget().getName() = "o" and
e.getCheckedType().(Class).hasQualifiedName("Expressions.Class")
select m, e