From 83fffa635093bd1790df6cf8d664a0991b0d22df Mon Sep 17 00:00:00 2001 From: Owen Mansel-Chan Date: Tue, 30 Jun 2020 18:37:00 +0100 Subject: [PATCH] Address review comments --- ql/src/semmle/go/dataflow/FunctionInputsAndOutputs.qll | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ql/src/semmle/go/dataflow/FunctionInputsAndOutputs.qll b/ql/src/semmle/go/dataflow/FunctionInputsAndOutputs.qll index 3d360812960..147f7209180 100644 --- a/ql/src/semmle/go/dataflow/FunctionInputsAndOutputs.qll +++ b/ql/src/semmle/go/dataflow/FunctionInputsAndOutputs.qll @@ -222,7 +222,7 @@ private class OutResult extends FunctionOutput, TOutResult { } } -/** A result position of a function, viewed as an output. */ +/** The receiver of a function, viewed as an output. */ private class OutReceiver extends FunctionOutput, TOutReceiver { override predicate isReceiver() { any() } @@ -242,13 +242,13 @@ private class OutReceiver extends FunctionOutput, TOutReceiver { override string toString() { result = "receiver" } } -/** A result position of a function, viewed as an output. */ +/** A parameter of a function, viewed as an output. */ private class OutParameter extends FunctionOutput, TOutParameter { int index; OutParameter() { this = TOutParameter(index) } - override predicate isParameter(int i) { i = index and i >= 0 } + override predicate isParameter(int i) { i = index } override DataFlow::Node getEntryNode(FuncDef f) { // there is no generic way of assigning to a parameter; operations that taint a parameter