mirror of
https://github.com/github/codeql.git
synced 2025-12-17 09:13:20 +01:00
14 lines
305 B
Plaintext
14 lines
305 B
Plaintext
/**
|
|
* @name Test for inline array access
|
|
*/
|
|
|
|
import csharp
|
|
|
|
from Method m, ArrayAccess e
|
|
where
|
|
m.hasName("MainAccesses") and
|
|
e.getEnclosingCallable() = m and
|
|
e.getQualifier().(LocalVariableAccess).getTarget().getName() = "inlinearray" and
|
|
e.getIndex(0).(IntLiteral).getValue() = "2"
|
|
select m, e
|