mirror of
https://github.com/github/codeql.git
synced 2025-12-18 01:33:15 +01:00
Some files that will change in #1736 have been spared. ./build -j4 target/jars/qlformat find ql/cpp/ql -name "*.ql" -print0 | xargs -0 target/jars/qlformat --input find ql/cpp/ql -name "*.qll" -print0 | xargs -0 target/jars/qlformat --input (cd ql && git checkout 'cpp/ql/src/semmle/code/cpp/ir/implementation/**/*SSA*.qll') buildutils-internal/scripts/pr-checks/sync-identical-files.py --latest
30 lines
845 B
Plaintext
30 lines
845 B
Plaintext
import cpp
|
|
|
|
string interesting(Element e) {
|
|
e instanceof Class and result = "Class"
|
|
or
|
|
e instanceof Function and result = "Function"
|
|
or
|
|
e instanceof FunctionDeclarationEntry and result = "FunctionDeclarationEntry"
|
|
or
|
|
e instanceof TypedefType and result = "TypedefType"
|
|
or
|
|
e instanceof Variable and result = "Variable"
|
|
or
|
|
e instanceof VariableDeclarationEntry and result = "VariableDeclarationEntry"
|
|
}
|
|
|
|
from Element e, string name, string specifier
|
|
where
|
|
(
|
|
name = e.(Declaration).getName() or
|
|
name = e.(DeclarationEntry).getName() or
|
|
name = e.(Type).toString()
|
|
) and
|
|
(
|
|
specifier = e.(Declaration).getASpecifier().toString() or
|
|
specifier = e.(DeclarationEntry).getASpecifier() or
|
|
specifier = e.(TypedefType).getBaseType().getASpecifier().toString()
|
|
)
|
|
select interesting(e), e, name, specifier
|