Skip to content

Commit 5202f96

Browse files
authored
C++: sync Operand source
1 parent 74c0197 commit 5202f96

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class Operand extends TStageOperand {
4646
/**
4747
* Gets the location of the source code for this operand.
4848
*/
49-
final Language::Location getLocation() { result = this.getUse().getLocation() }
49+
final Language::Location getLocation() { result = this.getAnyDef().getLocation() }
5050

5151
/**
5252
* Gets the function that contains this operand.

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class Operand extends TStageOperand {
4646
/**
4747
* Gets the location of the source code for this operand.
4848
*/
49-
final Language::Location getLocation() { result = this.getUse().getLocation() }
49+
final Language::Location getLocation() { result = this.getAnyDef().getLocation() }
5050

5151
/**
5252
* Gets the function that contains this operand.

csharp/ql/src/experimental/ir/implementation/raw/Operand.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class Operand extends TStageOperand {
4646
/**
4747
* Gets the location of the source code for this operand.
4848
*/
49-
final Language::Location getLocation() { result = this.getUse().getLocation() }
49+
final Language::Location getLocation() { result = this.getAnyDef().getLocation() }
5050

5151
/**
5252
* Gets the function that contains this operand.

csharp/ql/src/experimental/ir/implementation/unaliased_ssa/Operand.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class Operand extends TStageOperand {
4646
/**
4747
* Gets the location of the source code for this operand.
4848
*/
49-
final Language::Location getLocation() { result = this.getUse().getLocation() }
49+
final Language::Location getLocation() { result = this.getAnyDef().getLocation() }
5050

5151
/**
5252
* Gets the function that contains this operand.

0 commit comments

Comments
 (0)