Skip to content

Commit e9e09e7

Browse files
committed
C++: Sync identical files.
1 parent 896e087 commit e9e09e7

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/Instruction.qll

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1084,6 +1084,12 @@ class BinaryInstruction extends Instruction {
10841084
or
10851085
op1 = this.getRightOperand() and op2 = this.getLeftOperand()
10861086
}
1087+
1088+
/**
1089+
* Gets the instruction whose result provides the value of the left or right
1090+
* operand of this binary instruction.
1091+
*/
1092+
Instruction getAnInput() { result = this.getLeft() or result = this.getRight() }
10871093
}
10881094

10891095
/**

cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/Instruction.qll

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1084,6 +1084,12 @@ class BinaryInstruction extends Instruction {
10841084
or
10851085
op1 = this.getRightOperand() and op2 = this.getLeftOperand()
10861086
}
1087+
1088+
/**
1089+
* Gets the instruction whose result provides the value of the left or right
1090+
* operand of this binary instruction.
1091+
*/
1092+
Instruction getAnInput() { result = this.getLeft() or result = this.getRight() }
10871093
}
10881094

10891095
/**

0 commit comments

Comments
 (0)