Skip to content

Commit 0918e50

Browse files
committed
Swift: Switch pragma to inline_late.
1 parent 66637e8 commit 0918e50

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

swift/ql/lib/codeql/swift/dataflow/internal/TaintTrackingPublic.qll

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,14 @@ predicate localTaintStep = localTaintStepCached/2;
2626
* of `c` at sinks and inputs to additional taint steps.
2727
*/
2828
bindingset[node]
29+
pragma[inline_late]
2930
predicate defaultImplicitTaintRead(DataFlow::Node node, DataFlow::ContentSet cs) {
3031
// If a `PostUpdateNode` is specified as a sink, there's (almost) always a store step preceding it.
3132
// So when the node is a `PostUpdateNode` we allow any sequence of implicit read steps of an appropriate
3233
// type to make sure we arrive at the sink with an empty access path.
3334
exists(NominalTypeDecl d, Decl cx |
34-
pragma[only_bind_out](node)
35-
.(DataFlow::PostUpdateNode)
36-
.getPreUpdateNode()
37-
.asExpr()
38-
.getType()
39-
.getUnderlyingType() = d.getType().getABaseType*() and
35+
node.(DataFlow::PostUpdateNode).getPreUpdateNode().asExpr().getType().getUnderlyingType() =
36+
d.getType().getABaseType*() and
4037
cx.asNominalTypeDecl() = d and
4138
cs.getAReadContent().(DataFlow::Content::FieldContent).getField() = cx.getAMember()
4239
)

0 commit comments

Comments
 (0)