C++: autoformat

This commit is contained in:
Robert Marsh
2022-04-25 14:17:49 -04:00
parent f94fcf11cd
commit d0fc348ad9
3 changed files with 4 additions and 7 deletions

View File

@@ -80,9 +80,7 @@ abstract class TranslatedExpr extends TranslatedElement {
/** DEPRECATED: Alias for getAst */
deprecated override Locatable getAST() { result = this.getAst() }
final override Declaration getFunction() {
result = expr.getEnclosingDeclaration()
}
final override Declaration getFunction() { result = expr.getEnclosingDeclaration() }
/**
* Gets the expression from which this `TranslatedExpr` is generated.

View File

@@ -24,7 +24,8 @@ class TranslatedGlobalOrNamespaceVarInit extends TranslatedRootElement,
override Instruction getFirstInstruction() { result = this.getInstruction(EnterFunctionTag()) }
override TranslatedElement getChild(int n) {
n = 1 and result = getTranslatedInitialization(var.getInitializer().getExpr().getFullyConverted())
n = 1 and
result = getTranslatedInitialization(var.getInitializer().getExpr().getFullyConverted())
}
override predicate hasInstruction(Opcode op, InstructionTag tag, CppType type) {

View File

@@ -7,7 +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 shouldPrintFunction(Declaration decl) { shouldDumpFunction(decl) }
}