mirror of
https://github.com/github/codeql.git
synced 2026-04-27 17:55:19 +02:00
C++: Rename shouldPrintFunction to shouldPrintDeclaration
This commit is contained in:
@@ -7,5 +7,5 @@ private import semmle.code.cpp.PrintAST
|
||||
private import PrintConfig
|
||||
|
||||
private class PrintConfig extends PrintAstConfiguration {
|
||||
override predicate shouldPrintFunction(Function func) { shouldDumpFunction(func) }
|
||||
override predicate shouldPrintDeclaration(Declaration decl) { shouldDumpDeclaration(decl) }
|
||||
}
|
||||
|
||||
@@ -8,11 +8,11 @@ predicate locationIsInStandardHeaders(Location loc) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Holds if the AST or IR for the specified function should be printed in the test output.
|
||||
* Holds if the AST or IR for the specified declaration should be printed in the test output.
|
||||
*
|
||||
* This predicate excludes functions defined in standard headers.
|
||||
* This predicate excludes declarations defined in standard headers.
|
||||
*/
|
||||
predicate shouldDumpFunction(Declaration decl) {
|
||||
predicate shouldDumpDeclaration(Declaration decl) {
|
||||
not locationIsInStandardHeaders(decl.getLocation()) and
|
||||
(
|
||||
decl instanceof Function
|
||||
|
||||
@@ -7,5 +7,5 @@ private import semmle.code.cpp.ir.implementation.raw.PrintIR
|
||||
private import PrintConfig
|
||||
|
||||
private class PrintConfig extends PrintIRConfiguration {
|
||||
override predicate shouldPrintFunction(Declaration decl) { shouldDumpFunction(decl) }
|
||||
override predicate shouldPrintDeclaration(Declaration decl) { shouldDumpDeclaration(decl) }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user