Skip to content

Commit d108185

Browse files
authored
Merge pull request #12102 from jketema/fix-typos
C++: Fix some typos in the use-use dataflow code
2 parents 9e96d61 + 30952f6 commit d108185

File tree

3 files changed

+13
-13
lines changed

3 files changed

+13
-13
lines changed

cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowPrivate.qll

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -404,7 +404,7 @@ private Instruction getANonConversionUse(Operand operand) {
404404
* Gets the operand that represents the first use of the value of `call` following
405405
* a sequence of conversion-like instructions.
406406
*/
407-
predicate operandForfullyConvertedCall(Operand operand, CallInstruction call) {
407+
predicate operandForFullyConvertedCall(Operand operand, CallInstruction call) {
408408
exists(getANonConversionUse(operand)) and
409409
(
410410
operand = getAUse(call)
@@ -420,8 +420,8 @@ predicate operandForfullyConvertedCall(Operand operand, CallInstruction call) {
420420
* This predicate only holds if there is no suitable operand (i.e., no operand of a non-
421421
* conversion instruction) to use to represent the value of `call` after conversions.
422422
*/
423-
predicate instructionForfullyConvertedCall(Instruction instr, CallInstruction call) {
424-
not operandForfullyConvertedCall(_, call) and
423+
predicate instructionForFullyConvertedCall(Instruction instr, CallInstruction call) {
424+
not operandForFullyConvertedCall(_, call) and
425425
(
426426
// If there is no use of the call then we pick the call instruction
427427
not exists(getAUse(call)) and
@@ -436,9 +436,9 @@ predicate instructionForfullyConvertedCall(Instruction instr, CallInstruction ca
436436

437437
/** Holds if `node` represents the output node for `call`. */
438438
private predicate simpleOutNode(Node node, CallInstruction call) {
439-
operandForfullyConvertedCall(node.asOperand(), call)
439+
operandForFullyConvertedCall(node.asOperand(), call)
440440
or
441-
instructionForfullyConvertedCall(node.asInstruction(), call)
441+
instructionForFullyConvertedCall(node.asInstruction(), call)
442442
}
443443

444444
/** A data flow node that represents the output of a call. */

cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowUtil.qll

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -697,15 +697,15 @@ class IndirectArgumentOutNode extends Node, TIndirectArgumentOutNode, PartialDef
697697
pragma[nomagic]
698698
predicate indirectReturnOutNodeOperand0(CallInstruction call, Operand operand, int indirectionIndex) {
699699
Ssa::hasRawIndirectInstruction(call, indirectionIndex) and
700-
operandForfullyConvertedCall(operand, call)
700+
operandForFullyConvertedCall(operand, call)
701701
}
702702

703703
pragma[nomagic]
704704
predicate indirectReturnOutNodeInstruction0(
705705
CallInstruction call, Instruction instr, int indirectionIndex
706706
) {
707707
Ssa::hasRawIndirectInstruction(call, indirectionIndex) and
708-
instructionForfullyConvertedCall(instr, call)
708+
instructionForFullyConvertedCall(instr, call)
709709
}
710710

711711
/**
@@ -1392,7 +1392,7 @@ private module Cached {
13921392
)
13931393
or
13941394
// If an operand flows to an instruction, then the indirection of
1395-
// the operand also flows to the indirction of the instruction.
1395+
// the operand also flows to the indirection of the instruction.
13961396
exists(Operand operand, Instruction instr, int indirectionIndex |
13971397
simpleInstructionLocalFlowStep(operand, instr) and
13981398
hasOperandAndIndex(nodeFrom, operand, pragma[only_bind_into](indirectionIndex)) and
@@ -1539,7 +1539,7 @@ private module ExprFlowCached {
15391539

15401540
/**
15411541
* Holds if `n1.asExpr() = e1` and `n2.asExpr() = e2` and `n2` is the first node
1542-
* reacahble from `n1` such that `n2.asExpr()` exists.
1542+
* reachable from `n1` such that `n2.asExpr()` exists.
15431543
*/
15441544
private predicate localExprFlowSingleExprStep(Node n1, Expr e1, Node n2, Expr e2) {
15451545
exists(Node mid |

cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/SsaInternalsCommon.qll

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ private import DataFlowPrivate
99

1010
/**
1111
* Holds if `operand` is an operand that is not used by the dataflow library.
12-
* Ignored operands are not recognizd as uses by SSA, and they don't have a
12+
* Ignored operands are not recognized as uses by SSA, and they don't have a
1313
* corresponding `(Indirect)OperandNode`.
1414
*/
1515
predicate ignoreOperand(Operand operand) {
@@ -208,7 +208,7 @@ private module IteratorIndirections {
208208

209209
override predicate isAdditionalDereference(Instruction deref, Operand address) {
210210
exists(CallInstruction call |
211-
operandForfullyConvertedCall(getAUse(deref), call) and
211+
operandForFullyConvertedCall(getAUse(deref), call) and
212212
this = call.getStaticCallTarget().getClassAndName("operator*") and
213213
address = call.getThisArgumentOperand()
214214
)
@@ -739,7 +739,7 @@ private module Cached {
739739
* Holds if the underlying IR has a suitable instruction to represent a value
740740
* that would otherwise need to be represented by a dedicated `RawIndirectInstruction` value.
741741
*
742-
* Such instruction do not create new `RawIndirectOperand` values, but are
742+
* Such instructions do not create new `RawIndirectOperand` values, but are
743743
* instead associated with the instruction returned by this predicate.
744744
*/
745745
cached
@@ -807,7 +807,7 @@ private module Cached {
807807
}
808808

809809
/**
810-
* Holds if the address computed by `operand` is guarenteed to write
810+
* Holds if the address computed by `operand` is guaranteed to write
811811
* to a specific address.
812812
*/
813813
private predicate isCertainAddress(Operand operand) {

0 commit comments

Comments
 (0)