Files
codeql/cpp/ql/test/library-tests/fields/fields/EnumConst.ql
2018-08-24 11:58:58 -07:00

12 lines
343 B
Plaintext

/**
* @name EnumConst
* @kind table
*/
import cpp
from Enum e, Declaration c, string reason
where (c.(EnumConstant).getDeclaringEnum() = e and reason = "getDeclaringEnum()") or
(c.(EnumConstant).getType() = e and reason = "getType()") or
(c.(Field).getDeclaringType() = e and reason = "getDeclaringType()")
select e, c, reason