Skip to content

Commit 91ea064

Browse files
committed
Sync
1 parent df9836c commit 91ea064

File tree

18 files changed

+162
-126
lines changed

18 files changed

+162
-126
lines changed

cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl.qll

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ abstract class Configuration extends string {
110110
/**
111111
* Holds if data may flow from some source to `sink` for this configuration.
112112
*/
113-
predicate hasFlowTo(Node sink) { hasFlow(_, sink) }
113+
predicate hasFlowTo(Node sink) { this.hasFlow(_, sink) }
114114

115115
/**
116116
* Holds if data may flow from some source to `sink` for this configuration.
117117
*/
118-
predicate hasFlowToExpr(DataFlowExpr sink) { hasFlowTo(exprNode(sink)) }
118+
predicate hasFlowToExpr(DataFlowExpr sink) { this.hasFlowTo(exprNode(sink)) }
119119

120120
/**
121121
* Gets the exploration limit for `hasPartialFlow` and `hasPartialFlowRev`
@@ -3170,7 +3170,7 @@ private class AccessPathCons extends AccessPath, TAccessPathCons {
31703170
}
31713171

31723172
override string toString() {
3173-
result = "[" + this.toStringImpl(true) + length().toString() + ")]"
3173+
result = "[" + this.toStringImpl(true) + this.length().toString() + ")]"
31743174
or
31753175
result = "[" + this.toStringImpl(false)
31763176
}
@@ -3309,9 +3309,11 @@ abstract private class PathNodeImpl extends PathNode {
33093309
result = " <" + this.(PathNodeMid).getCallContext().toString() + ">"
33103310
}
33113311

3312-
override string toString() { result = this.getNodeEx().toString() + ppAp() }
3312+
override string toString() { result = this.getNodeEx().toString() + this.ppAp() }
33133313

3314-
override string toStringWithContext() { result = this.getNodeEx().toString() + ppAp() + ppCtx() }
3314+
override string toStringWithContext() {
3315+
result = this.getNodeEx().toString() + this.ppAp() + this.ppCtx()
3316+
}
33153317

33163318
override predicate hasLocationInfo(
33173319
string filepath, int startline, int startcolumn, int endline, int endcolumn
@@ -3379,11 +3381,11 @@ private class PathNodeMid extends PathNodeImpl, TPathNodeMid {
33793381

33803382
override PathNodeImpl getASuccessorImpl() {
33813383
// an intermediate step to another intermediate node
3382-
result = getSuccMid()
3384+
result = this.getSuccMid()
33833385
or
33843386
// a final step to a sink via zero steps means we merge the last two steps to prevent trivial-looking edges
33853387
exists(PathNodeMid mid, PathNodeSink sink |
3386-
mid = getSuccMid() and
3388+
mid = this.getSuccMid() and
33873389
mid.getNodeEx() = sink.getNodeEx() and
33883390
mid.getAp() instanceof AccessPathNil and
33893391
sink.getConfiguration() = unbindConf(mid.getConfiguration()) and

cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl2.qll

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ abstract class Configuration extends string {
110110
/**
111111
* Holds if data may flow from some source to `sink` for this configuration.
112112
*/
113-
predicate hasFlowTo(Node sink) { hasFlow(_, sink) }
113+
predicate hasFlowTo(Node sink) { this.hasFlow(_, sink) }
114114

115115
/**
116116
* Holds if data may flow from some source to `sink` for this configuration.
117117
*/
118-
predicate hasFlowToExpr(DataFlowExpr sink) { hasFlowTo(exprNode(sink)) }
118+
predicate hasFlowToExpr(DataFlowExpr sink) { this.hasFlowTo(exprNode(sink)) }
119119

120120
/**
121121
* Gets the exploration limit for `hasPartialFlow` and `hasPartialFlowRev`
@@ -3170,7 +3170,7 @@ private class AccessPathCons extends AccessPath, TAccessPathCons {
31703170
}
31713171

31723172
override string toString() {
3173-
result = "[" + this.toStringImpl(true) + length().toString() + ")]"
3173+
result = "[" + this.toStringImpl(true) + this.length().toString() + ")]"
31743174
or
31753175
result = "[" + this.toStringImpl(false)
31763176
}
@@ -3309,9 +3309,11 @@ abstract private class PathNodeImpl extends PathNode {
33093309
result = " <" + this.(PathNodeMid).getCallContext().toString() + ">"
33103310
}
33113311

3312-
override string toString() { result = this.getNodeEx().toString() + ppAp() }
3312+
override string toString() { result = this.getNodeEx().toString() + this.ppAp() }
33133313

3314-
override string toStringWithContext() { result = this.getNodeEx().toString() + ppAp() + ppCtx() }
3314+
override string toStringWithContext() {
3315+
result = this.getNodeEx().toString() + this.ppAp() + this.ppCtx()
3316+
}
33153317

33163318
override predicate hasLocationInfo(
33173319
string filepath, int startline, int startcolumn, int endline, int endcolumn
@@ -3379,11 +3381,11 @@ private class PathNodeMid extends PathNodeImpl, TPathNodeMid {
33793381

33803382
override PathNodeImpl getASuccessorImpl() {
33813383
// an intermediate step to another intermediate node
3382-
result = getSuccMid()
3384+
result = this.getSuccMid()
33833385
or
33843386
// a final step to a sink via zero steps means we merge the last two steps to prevent trivial-looking edges
33853387
exists(PathNodeMid mid, PathNodeSink sink |
3386-
mid = getSuccMid() and
3388+
mid = this.getSuccMid() and
33873389
mid.getNodeEx() = sink.getNodeEx() and
33883390
mid.getAp() instanceof AccessPathNil and
33893391
sink.getConfiguration() = unbindConf(mid.getConfiguration()) and

cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl3.qll

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ abstract class Configuration extends string {
110110
/**
111111
* Holds if data may flow from some source to `sink` for this configuration.
112112
*/
113-
predicate hasFlowTo(Node sink) { hasFlow(_, sink) }
113+
predicate hasFlowTo(Node sink) { this.hasFlow(_, sink) }
114114

115115
/**
116116
* Holds if data may flow from some source to `sink` for this configuration.
117117
*/
118-
predicate hasFlowToExpr(DataFlowExpr sink) { hasFlowTo(exprNode(sink)) }
118+
predicate hasFlowToExpr(DataFlowExpr sink) { this.hasFlowTo(exprNode(sink)) }
119119

120120
/**
121121
* Gets the exploration limit for `hasPartialFlow` and `hasPartialFlowRev`
@@ -3170,7 +3170,7 @@ private class AccessPathCons extends AccessPath, TAccessPathCons {
31703170
}
31713171

31723172
override string toString() {
3173-
result = "[" + this.toStringImpl(true) + length().toString() + ")]"
3173+
result = "[" + this.toStringImpl(true) + this.length().toString() + ")]"
31743174
or
31753175
result = "[" + this.toStringImpl(false)
31763176
}
@@ -3309,9 +3309,11 @@ abstract private class PathNodeImpl extends PathNode {
33093309
result = " <" + this.(PathNodeMid).getCallContext().toString() + ">"
33103310
}
33113311

3312-
override string toString() { result = this.getNodeEx().toString() + ppAp() }
3312+
override string toString() { result = this.getNodeEx().toString() + this.ppAp() }
33133313

3314-
override string toStringWithContext() { result = this.getNodeEx().toString() + ppAp() + ppCtx() }
3314+
override string toStringWithContext() {
3315+
result = this.getNodeEx().toString() + this.ppAp() + this.ppCtx()
3316+
}
33153317

33163318
override predicate hasLocationInfo(
33173319
string filepath, int startline, int startcolumn, int endline, int endcolumn
@@ -3379,11 +3381,11 @@ private class PathNodeMid extends PathNodeImpl, TPathNodeMid {
33793381

33803382
override PathNodeImpl getASuccessorImpl() {
33813383
// an intermediate step to another intermediate node
3382-
result = getSuccMid()
3384+
result = this.getSuccMid()
33833385
or
33843386
// a final step to a sink via zero steps means we merge the last two steps to prevent trivial-looking edges
33853387
exists(PathNodeMid mid, PathNodeSink sink |
3386-
mid = getSuccMid() and
3388+
mid = this.getSuccMid() and
33873389
mid.getNodeEx() = sink.getNodeEx() and
33883390
mid.getAp() instanceof AccessPathNil and
33893391
sink.getConfiguration() = unbindConf(mid.getConfiguration()) and

cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl4.qll

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ abstract class Configuration extends string {
110110
/**
111111
* Holds if data may flow from some source to `sink` for this configuration.
112112
*/
113-
predicate hasFlowTo(Node sink) { hasFlow(_, sink) }
113+
predicate hasFlowTo(Node sink) { this.hasFlow(_, sink) }
114114

115115
/**
116116
* Holds if data may flow from some source to `sink` for this configuration.
117117
*/
118-
predicate hasFlowToExpr(DataFlowExpr sink) { hasFlowTo(exprNode(sink)) }
118+
predicate hasFlowToExpr(DataFlowExpr sink) { this.hasFlowTo(exprNode(sink)) }
119119

120120
/**
121121
* Gets the exploration limit for `hasPartialFlow` and `hasPartialFlowRev`
@@ -3170,7 +3170,7 @@ private class AccessPathCons extends AccessPath, TAccessPathCons {
31703170
}
31713171

31723172
override string toString() {
3173-
result = "[" + this.toStringImpl(true) + length().toString() + ")]"
3173+
result = "[" + this.toStringImpl(true) + this.length().toString() + ")]"
31743174
or
31753175
result = "[" + this.toStringImpl(false)
31763176
}
@@ -3309,9 +3309,11 @@ abstract private class PathNodeImpl extends PathNode {
33093309
result = " <" + this.(PathNodeMid).getCallContext().toString() + ">"
33103310
}
33113311

3312-
override string toString() { result = this.getNodeEx().toString() + ppAp() }
3312+
override string toString() { result = this.getNodeEx().toString() + this.ppAp() }
33133313

3314-
override string toStringWithContext() { result = this.getNodeEx().toString() + ppAp() + ppCtx() }
3314+
override string toStringWithContext() {
3315+
result = this.getNodeEx().toString() + this.ppAp() + this.ppCtx()
3316+
}
33153317

33163318
override predicate hasLocationInfo(
33173319
string filepath, int startline, int startcolumn, int endline, int endcolumn
@@ -3379,11 +3381,11 @@ private class PathNodeMid extends PathNodeImpl, TPathNodeMid {
33793381

33803382
override PathNodeImpl getASuccessorImpl() {
33813383
// an intermediate step to another intermediate node
3382-
result = getSuccMid()
3384+
result = this.getSuccMid()
33833385
or
33843386
// a final step to a sink via zero steps means we merge the last two steps to prevent trivial-looking edges
33853387
exists(PathNodeMid mid, PathNodeSink sink |
3386-
mid = getSuccMid() and
3388+
mid = this.getSuccMid() and
33873389
mid.getNodeEx() = sink.getNodeEx() and
33883390
mid.getAp() instanceof AccessPathNil and
33893391
sink.getConfiguration() = unbindConf(mid.getConfiguration()) and

cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImplLocal.qll

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ abstract class Configuration extends string {
110110
/**
111111
* Holds if data may flow from some source to `sink` for this configuration.
112112
*/
113-
predicate hasFlowTo(Node sink) { hasFlow(_, sink) }
113+
predicate hasFlowTo(Node sink) { this.hasFlow(_, sink) }
114114

115115
/**
116116
* Holds if data may flow from some source to `sink` for this configuration.
117117
*/
118-
predicate hasFlowToExpr(DataFlowExpr sink) { hasFlowTo(exprNode(sink)) }
118+
predicate hasFlowToExpr(DataFlowExpr sink) { this.hasFlowTo(exprNode(sink)) }
119119

120120
/**
121121
* Gets the exploration limit for `hasPartialFlow` and `hasPartialFlowRev`
@@ -3170,7 +3170,7 @@ private class AccessPathCons extends AccessPath, TAccessPathCons {
31703170
}
31713171

31723172
override string toString() {
3173-
result = "[" + this.toStringImpl(true) + length().toString() + ")]"
3173+
result = "[" + this.toStringImpl(true) + this.length().toString() + ")]"
31743174
or
31753175
result = "[" + this.toStringImpl(false)
31763176
}
@@ -3309,9 +3309,11 @@ abstract private class PathNodeImpl extends PathNode {
33093309
result = " <" + this.(PathNodeMid).getCallContext().toString() + ">"
33103310
}
33113311

3312-
override string toString() { result = this.getNodeEx().toString() + ppAp() }
3312+
override string toString() { result = this.getNodeEx().toString() + this.ppAp() }
33133313

3314-
override string toStringWithContext() { result = this.getNodeEx().toString() + ppAp() + ppCtx() }
3314+
override string toStringWithContext() {
3315+
result = this.getNodeEx().toString() + this.ppAp() + this.ppCtx()
3316+
}
33153317

33163318
override predicate hasLocationInfo(
33173319
string filepath, int startline, int startcolumn, int endline, int endcolumn
@@ -3379,11 +3381,11 @@ private class PathNodeMid extends PathNodeImpl, TPathNodeMid {
33793381

33803382
override PathNodeImpl getASuccessorImpl() {
33813383
// an intermediate step to another intermediate node
3382-
result = getSuccMid()
3384+
result = this.getSuccMid()
33833385
or
33843386
// a final step to a sink via zero steps means we merge the last two steps to prevent trivial-looking edges
33853387
exists(PathNodeMid mid, PathNodeSink sink |
3386-
mid = getSuccMid() and
3388+
mid = this.getSuccMid() and
33873389
mid.getNodeEx() = sink.getNodeEx() and
33883390
mid.getAp() instanceof AccessPathNil and
33893391
sink.getConfiguration() = unbindConf(mid.getConfiguration()) and

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

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ abstract class Configuration extends string {
110110
/**
111111
* Holds if data may flow from some source to `sink` for this configuration.
112112
*/
113-
predicate hasFlowTo(Node sink) { hasFlow(_, sink) }
113+
predicate hasFlowTo(Node sink) { this.hasFlow(_, sink) }
114114

115115
/**
116116
* Holds if data may flow from some source to `sink` for this configuration.
117117
*/
118-
predicate hasFlowToExpr(DataFlowExpr sink) { hasFlowTo(exprNode(sink)) }
118+
predicate hasFlowToExpr(DataFlowExpr sink) { this.hasFlowTo(exprNode(sink)) }
119119

120120
/**
121121
* Gets the exploration limit for `hasPartialFlow` and `hasPartialFlowRev`
@@ -3170,7 +3170,7 @@ private class AccessPathCons extends AccessPath, TAccessPathCons {
31703170
}
31713171

31723172
override string toString() {
3173-
result = "[" + this.toStringImpl(true) + length().toString() + ")]"
3173+
result = "[" + this.toStringImpl(true) + this.length().toString() + ")]"
31743174
or
31753175
result = "[" + this.toStringImpl(false)
31763176
}
@@ -3309,9 +3309,11 @@ abstract private class PathNodeImpl extends PathNode {
33093309
result = " <" + this.(PathNodeMid).getCallContext().toString() + ">"
33103310
}
33113311

3312-
override string toString() { result = this.getNodeEx().toString() + ppAp() }
3312+
override string toString() { result = this.getNodeEx().toString() + this.ppAp() }
33133313

3314-
override string toStringWithContext() { result = this.getNodeEx().toString() + ppAp() + ppCtx() }
3314+
override string toStringWithContext() {
3315+
result = this.getNodeEx().toString() + this.ppAp() + this.ppCtx()
3316+
}
33153317

33163318
override predicate hasLocationInfo(
33173319
string filepath, int startline, int startcolumn, int endline, int endcolumn
@@ -3379,11 +3381,11 @@ private class PathNodeMid extends PathNodeImpl, TPathNodeMid {
33793381

33803382
override PathNodeImpl getASuccessorImpl() {
33813383
// an intermediate step to another intermediate node
3382-
result = getSuccMid()
3384+
result = this.getSuccMid()
33833385
or
33843386
// a final step to a sink via zero steps means we merge the last two steps to prevent trivial-looking edges
33853387
exists(PathNodeMid mid, PathNodeSink sink |
3386-
mid = getSuccMid() and
3388+
mid = this.getSuccMid() and
33873389
mid.getNodeEx() = sink.getNodeEx() and
33883390
mid.getAp() instanceof AccessPathNil and
33893391
sink.getConfiguration() = unbindConf(mid.getConfiguration()) and

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

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,12 @@ abstract class Configuration extends string {
110110
/**
111111
* Holds if data may flow from some source to `sink` for this configuration.
112112
*/
113-
predicate hasFlowTo(Node sink) { hasFlow(_, sink) }
113+
predicate hasFlowTo(Node sink) { this.hasFlow(_, sink) }
114114

115115
/**
116116
* Holds if data may flow from some source to `sink` for this configuration.
117117
*/
118-
predicate hasFlowToExpr(DataFlowExpr sink) { hasFlowTo(exprNode(sink)) }
118+
predicate hasFlowToExpr(DataFlowExpr sink) { this.hasFlowTo(exprNode(sink)) }
119119

120120
/**
121121
* Gets the exploration limit for `hasPartialFlow` and `hasPartialFlowRev`
@@ -3170,7 +3170,7 @@ private class AccessPathCons extends AccessPath, TAccessPathCons {
31703170
}
31713171

31723172
override string toString() {
3173-
result = "[" + this.toStringImpl(true) + length().toString() + ")]"
3173+
result = "[" + this.toStringImpl(true) + this.length().toString() + ")]"
31743174
or
31753175
result = "[" + this.toStringImpl(false)
31763176
}
@@ -3309,9 +3309,11 @@ abstract private class PathNodeImpl extends PathNode {
33093309
result = " <" + this.(PathNodeMid).getCallContext().toString() + ">"
33103310
}
33113311

3312-
override string toString() { result = this.getNodeEx().toString() + ppAp() }
3312+
override string toString() { result = this.getNodeEx().toString() + this.ppAp() }
33133313

3314-
override string toStringWithContext() { result = this.getNodeEx().toString() + ppAp() + ppCtx() }
3314+
override string toStringWithContext() {
3315+
result = this.getNodeEx().toString() + this.ppAp() + this.ppCtx()
3316+
}
33153317

33163318
override predicate hasLocationInfo(
33173319
string filepath, int startline, int startcolumn, int endline, int endcolumn
@@ -3379,11 +3381,11 @@ private class PathNodeMid extends PathNodeImpl, TPathNodeMid {
33793381

33803382
override PathNodeImpl getASuccessorImpl() {
33813383
// an intermediate step to another intermediate node
3382-
result = getSuccMid()
3384+
result = this.getSuccMid()
33833385
or
33843386
// a final step to a sink via zero steps means we merge the last two steps to prevent trivial-looking edges
33853387
exists(PathNodeMid mid, PathNodeSink sink |
3386-
mid = getSuccMid() and
3388+
mid = this.getSuccMid() and
33873389
mid.getNodeEx() = sink.getNodeEx() and
33883390
mid.getAp() instanceof AccessPathNil and
33893391
sink.getConfiguration() = unbindConf(mid.getConfiguration()) and

0 commit comments

Comments
 (0)