@@ -196,11 +196,16 @@ string getComponentSpecific(SummaryComponent sc) {
196
196
exists ( Content c | sc = TContentSummaryComponent ( c ) and result = getContentSpecific ( c ) )
197
197
}
198
198
199
+ bindingset [ pos]
200
+ private string positionToString ( int pos ) {
201
+ if pos = - 1 then result = "this" else result = pos .toString ( )
202
+ }
203
+
199
204
/** Gets the textual representation of a parameter position in the format used for flow summaries. */
200
- string getParameterPosition ( ParameterPosition pos ) { result = pos . toString ( ) }
205
+ string getParameterPosition ( ParameterPosition pos ) { result = positionToString ( pos ) }
201
206
202
207
/** Gets the textual representation of an argument position in the format used for flow summaries. */
203
- string getArgumentPosition ( ArgumentPosition pos ) { result = pos . toString ( ) }
208
+ string getArgumentPosition ( ArgumentPosition pos ) { result = positionToString ( pos ) }
204
209
205
210
/** Holds if input specification component `c` needs a reference. */
206
211
predicate inputNeedsReferenceSpecific ( string c ) { none ( ) }
@@ -314,8 +319,16 @@ predicate interpretInputSpecific(string c, InterpretNode mid, InterpretNode n) {
314
319
315
320
/** Gets the argument position obtained by parsing `X` in `Parameter[X]`. */
316
321
bindingset [ s]
317
- ArgumentPosition parseParamBody ( string s ) { result = AccessPath:: parseInt ( s ) }
322
+ ArgumentPosition parseParamBody ( string s ) {
323
+ result = AccessPath:: parseInt ( s )
324
+ or
325
+ s = "this" and result = - 1
326
+ }
318
327
319
328
/** Gets the parameter position obtained by parsing `X` in `Argument[X]`. */
320
329
bindingset [ s]
321
- ParameterPosition parseArgBody ( string s ) { result = AccessPath:: parseInt ( s ) }
330
+ ParameterPosition parseArgBody ( string s ) {
331
+ result = AccessPath:: parseInt ( s )
332
+ or
333
+ s = "this" and result = - 1
334
+ }
0 commit comments