@@ -204,18 +204,6 @@ module API {
204
204
Impl:: positionalParameterOrArgumentEdge ( this .getAnEpsilonSuccessor ( ) , n , result )
205
205
}
206
206
207
- /**
208
- * Gets the given keyword parameter of this callable, or keyword argument to this call.
209
- *
210
- * Note: for historical reasons, this predicate may refer to an argument of a call, but this may change in the future.
211
- * When referring to an argument, it is recommended to use `getKeywordArgument(n)` instead.
212
- */
213
- pragma [ inline]
214
- Node getKeywordParameter ( string name ) {
215
- // This predicate is currently not 'inline_late' because 'name' can be an input or output
216
- Impl:: keywordParameterOrArgumentEdge ( this .getAnEpsilonSuccessor ( ) , name , result )
217
- }
218
-
219
207
/**
220
208
* Gets the argument passed in argument position `pos` at this call.
221
209
*/
@@ -260,15 +248,6 @@ module API {
260
248
result = this .getContent ( contents .getAReadContent ( ) )
261
249
}
262
250
263
- /**
264
- * Gets a representative for the instance field of the given `name`.
265
- */
266
- pragma [ inline]
267
- Node getField ( string name ) {
268
- // This predicate is currently not 'inline_late' because 'name' can be an input or output
269
- Impl:: fieldEdge ( this .getAnEpsilonSuccessor ( ) , name , result )
270
- }
271
-
272
251
/**
273
252
* Gets a representative for an arbitrary element of this collection.
274
253
*/
@@ -405,13 +384,6 @@ module API {
405
384
/** Gets the root node. */
406
385
Node root ( ) { result instanceof RootNode }
407
386
408
- bindingset [ name]
409
- pragma [ inline_late]
410
- Node namespace ( string name ) {
411
- // This predicate is currently not 'inline_late' because 'n' can be an input or output
412
- Impl:: namespace ( name , result )
413
- }
414
-
415
387
pragma [ inline]
416
388
Node getTopLevelMember ( string name ) { Impl:: topLevelMember ( name , result ) }
417
389
@@ -516,43 +488,6 @@ module API {
516
488
)
517
489
}
518
490
519
- cached
520
- predicate callEdge ( Node pred , string name , Node succ ) {
521
- exists ( DataFlow:: CallNode call |
522
- // from receiver to method call node
523
- pred = getForwardEndNode ( getALocalSourceStrict ( call .getQualifier ( ) ) ) and
524
- succ = MkMethodAccessNode ( call ) and
525
- name = call .getLowerCaseName ( )
526
- )
527
- }
528
-
529
- bindingset [ name]
530
- private string memberOrMethodReturnValue ( string name ) {
531
- // This predicate is a bit ad-hoc, but it's okay for now.
532
- // We can delete it once we no longer use the typeModel and summaryModel
533
- // tables to represent implicit root members.
534
- result = "Method[" + name + "]"
535
- or
536
- result = "Method[" + name + "].ReturnValue"
537
- or
538
- result = "Member[" + name + "]"
539
- }
540
-
541
- private Node getAnImplicitRootMember ( string name ) {
542
- exists ( DataFlow:: CallNode call |
543
- Extensions:: typeModel ( _, Specific:: getAnImplicitImport ( ) , memberOrMethodReturnValue ( name ) )
544
- or
545
- Extensions:: summaryModel ( Specific:: getAnImplicitImport ( ) , memberOrMethodReturnValue ( name ) ,
546
- _, _, _, _)
547
- or
548
- Extensions:: sourceModel ( Specific:: getAnImplicitImport ( ) , memberOrMethodReturnValue ( name ) , _,
549
- _)
550
- |
551
- result = MkMethodAccessNode ( call ) and
552
- name = call .getLowerCaseName ( )
553
- )
554
- }
555
-
556
491
cached
557
492
predicate memberEdge ( Node pred , string name , Node succ ) {
558
493
pred = API:: root ( ) and
@@ -617,11 +552,6 @@ module API {
617
552
)
618
553
}
619
554
620
- cached
621
- predicate fieldEdge ( Node pred , string name , Node succ ) {
622
- Impl:: contentEdge ( pred , DataFlowPrivate:: TFieldContent ( name ) , succ )
623
- }
624
-
625
555
cached
626
556
predicate elementEdge ( Node pred , Node succ ) {
627
557
contentEdge ( pred , any ( DataFlow:: ContentSet set | set .isAnyElement ( ) ) .getAReadContent ( ) , succ )
@@ -665,24 +595,13 @@ module API {
665
595
) , succ )
666
596
}
667
597
668
- private predicate keywordParameterEdge ( Node pred , string name , Node succ ) {
669
- parameterEdge ( pred , any ( DataFlowDispatch:: ParameterPosition pos | pos .isKeyword ( name ) ) , succ )
670
- }
671
-
672
598
cached
673
599
predicate positionalParameterOrArgumentEdge ( Node pred , int n , Node succ ) {
674
600
positionalArgumentEdge ( pred , n , succ )
675
601
or
676
602
positionalParameterEdge ( pred , n , succ )
677
603
}
678
604
679
- cached
680
- predicate keywordParameterOrArgumentEdge ( Node pred , string name , Node succ ) {
681
- keywordArgumentEdge ( pred , name , succ )
682
- or
683
- keywordParameterEdge ( pred , name , succ )
684
- }
685
-
686
605
cached
687
606
predicate instanceEdge ( Node pred , Node succ ) {
688
607
// TODO: Also model parameters with a given type here
0 commit comments