mirror of
https://github.com/github/codeql.git
synced 2026-05-24 16:17:07 +02:00
C++: Add missing overrides.
This commit is contained in:
@@ -1357,6 +1357,16 @@ class PhiNode extends Definition instanceof SsaImpl::PhiNode {
|
||||
final predicate hasInputFromBlock(Definition input, IRBlock bb) {
|
||||
phiHasInputFromBlock(this, input, bb)
|
||||
}
|
||||
|
||||
override int getIndirection() { result = this.getSourceVariable().getIndirection() }
|
||||
|
||||
override predicate isCertain() {
|
||||
forex(Definition inp | inp = this.getAnInput() | inp.isCertain())
|
||||
}
|
||||
|
||||
final override Declaration getFunction() {
|
||||
result = SsaImpl::PhiNode.super.getBasicBlock().getEnclosingFunction()
|
||||
}
|
||||
}
|
||||
|
||||
/** An static single assignment (SSA) definition. */
|
||||
|
||||
@@ -28,7 +28,7 @@ void test2(bool b) { // $ certain="SSA def(&b)" certain="SSA def(b)"
|
||||
} else {
|
||||
x = 1; // $ certain="SSA def(x)"
|
||||
}
|
||||
use(x); // $ uncertain="SSA phi(x)"
|
||||
use(x); // $ certain="SSA phi(x)"
|
||||
}
|
||||
|
||||
{
|
||||
@@ -38,7 +38,7 @@ void test2(bool b) { // $ certain="SSA def(&b)" certain="SSA def(b)"
|
||||
} else {
|
||||
|
||||
}
|
||||
use(x); // $ uncertain="SSA phi(x)"
|
||||
use(x); // $ certain="SSA phi(x)"
|
||||
}
|
||||
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user