3
3
*/
4
4
5
5
private import go
6
+ private import DataFlowDispatch
6
7
private import DataFlowPrivate
7
8
private import DataFlowUtil
8
9
private import FlowSummaryImpl:: Private
@@ -18,40 +19,6 @@ class SummarizedCallableBase = Callable;
18
19
19
20
DataFlowCallable inject ( SummarizedCallable c ) { result .asCallable ( ) = c }
20
21
21
- /** Holds if `i` is a valid parameter position. */
22
- predicate parameterPosition ( int i ) {
23
- i = [ - 1 .. any ( DataFlowCallable c ) .getType ( ) .getNumParameter ( ) ]
24
- }
25
-
26
- /** Gets the parameter position of the instance parameter. */
27
- int instanceParameterPosition ( ) { result = - 1 }
28
-
29
- /** A parameter position represented by an integer. */
30
- class ParameterPosition extends int {
31
- ParameterPosition ( ) { parameterPosition ( this ) }
32
- }
33
-
34
- /** An argument position represented by an integer. */
35
- class ArgumentPosition extends int {
36
- ArgumentPosition ( ) { parameterPosition ( this ) }
37
- }
38
-
39
- /** Holds if arguments at position `apos` match parameters at position `ppos`. */
40
- pragma [ inline]
41
- predicate parameterMatch ( ParameterPosition ppos , ArgumentPosition apos ) { ppos = apos }
42
-
43
- /**
44
- * Holds if `arg` is an argument of `call` with an argument position that matches
45
- * parameter position `ppos`.
46
- */
47
- pragma [ noinline]
48
- predicate argumentPositionMatch ( DataFlowCall call , ArgNode arg , ParameterPosition ppos ) {
49
- exists ( ArgumentPosition apos |
50
- arg .argumentOf ( call , apos ) and
51
- parameterMatch ( ppos , apos )
52
- )
53
- }
54
-
55
22
/** Gets the textual representation of a parameter position in the format used for flow summaries. */
56
23
string getParameterPositionCsv ( ParameterPosition pos ) { result = pos .toString ( ) }
57
24
0 commit comments