@@ -774,17 +774,18 @@ module MakeImplCommon<InputSig Lang> {
774774 }
775775
776776 /**
777- * Gets a viable run-time dispatch target for the call `call` in the
778- * context `ctx`. This is restricted to those calls and results for which
779- * the return flow from the result to `call` restricts the possible context
780- * `ctx`.
777+ * Gets a viable call site for the return from `callable` in call context
778+ * `ctx`. This is restricted to those callables and contexts for which
779+ * the possible call sites are restricted.
781780 */
782781 cached
783- DataFlowCallable prunedViableImplInCallContextReverse ( DataFlowCall call , CallContextReturn ctx ) {
782+ DataFlowCall prunedViableImplInCallContextReverse (
783+ DataFlowCallable callable , CallContextReturn ctx
784+ ) {
784785 exists ( DataFlowCallable c0 , DataFlowCall call0 |
785- callEnclosingCallable ( call0 , result ) and
786+ callEnclosingCallable ( call0 , callable ) and
786787 ctx = TReturn ( c0 , call0 ) and
787- c0 = viableImplInCallContextExt ( call0 , call ) and
788+ c0 = viableImplInCallContextExt ( call0 , result ) and
788789 reducedViableImplInReturn ( c0 , call0 )
789790 )
790791 }
@@ -1305,7 +1306,7 @@ module MakeImplCommon<InputSig Lang> {
13051306 predicate resolveReturn ( CallContext cc , DataFlowCallable callable , DataFlowCall call ) {
13061307 cc instanceof CallContextAny and callable = viableCallableExt ( call )
13071308 or
1308- callable = prunedViableImplInCallContextReverse ( call , cc )
1309+ call = prunedViableImplInCallContextReverse ( callable , cc )
13091310 }
13101311
13111312 /**
0 commit comments