File tree Expand file tree Collapse file tree 1 file changed +30
-2
lines changed
ruby/ql/lib/codeql/ruby/dataflow/internal Expand file tree Collapse file tree 1 file changed +30
-2
lines changed Original file line number Diff line number Diff line change @@ -79,10 +79,38 @@ SummaryComponent interpretComponentSpecific(AccessPathToken c) {
7979string getComponentSpecificCsv ( SummaryComponent sc ) { none ( ) }
8080
8181/** Gets the textual representation of a parameter position in the format used for flow summaries. */
82- string getParameterPositionCsv ( ParameterPosition pos ) { result = pos .toString ( ) }
82+ string getParameterPositionCsv ( ParameterPosition pos ) {
83+ pos .isSelf ( ) and result = "self"
84+ or
85+ pos .isBlock ( ) and result = "block"
86+ or
87+ exists ( int i |
88+ pos .isPositional ( i ) and
89+ result = i .toString ( )
90+ )
91+ or
92+ exists ( string name |
93+ pos .isKeyword ( name ) and
94+ result = name + ":"
95+ )
96+ }
8397
8498/** Gets the textual representation of an argument position in the format used for flow summaries. */
85- string getArgumentPositionCsv ( ArgumentPosition pos ) { result = pos .toString ( ) }
99+ string getArgumentPositionCsv ( ArgumentPosition pos ) {
100+ pos .isSelf ( ) and result = "self"
101+ or
102+ pos .isBlock ( ) and result = "block"
103+ or
104+ exists ( int i |
105+ pos .isPositional ( i ) and
106+ result = i .toString ( )
107+ )
108+ or
109+ exists ( string name |
110+ pos .isKeyword ( name ) and
111+ result = name + ":"
112+ )
113+ }
86114
87115/** Holds if input specification component `c` needs a reference. */
88116predicate inputNeedsReferenceSpecific ( string c ) { none ( ) }
You can’t perform that action at this time.
0 commit comments