refactoring: record copy of resolved call explicitly
This commit is contained in:
@@ -60,6 +60,7 @@ import static org.jetbrains.jet.lang.descriptors.ReceiverParameterDescriptor.NO_
|
||||
import static org.jetbrains.jet.lang.diagnostics.Errors.*;
|
||||
import static org.jetbrains.jet.lang.resolve.BindingContext.NON_DEFAULT_EXPRESSION_DATA_FLOW;
|
||||
import static org.jetbrains.jet.lang.resolve.BindingContext.RESOLUTION_SCOPE;
|
||||
import static org.jetbrains.jet.lang.resolve.BindingContext.RESOLVED_CALL;
|
||||
import static org.jetbrains.jet.lang.resolve.calls.CallResolverUtil.ResolveArgumentsMode.RESOLVE_FUNCTION_ARGUMENTS;
|
||||
import static org.jetbrains.jet.lang.resolve.calls.results.OverloadResolutionResults.Code.*;
|
||||
import static org.jetbrains.jet.lang.resolve.scopes.receivers.ReceiverValue.NO_RECEIVER;
|
||||
@@ -374,7 +375,9 @@ public class CallResolver {
|
||||
candidateResolver.checkValueArgumentTypes(callCandidateResolutionContext);
|
||||
return results;
|
||||
}
|
||||
ResolvedCallImpl<D> copy = CallResolverUtil.copy(resolvedCall, context);
|
||||
ResolvedCallImpl<D> copy = CallResolverUtil.copy(resolvedCall);
|
||||
context.trace.record(RESOLVED_CALL, context.call.getCalleeExpression(), copy);
|
||||
|
||||
CallCandidateResolutionContext<D> callCandidateResolutionContext =
|
||||
CallCandidateResolutionContext.createForCallBeingAnalyzed(copy, context, tracing);
|
||||
candidateResolver.completeTypeInferenceDependentOnExpectedTypeForCall(callCandidateResolutionContext, false);
|
||||
|
||||
@@ -52,13 +52,13 @@ public class CallResolverUtil {
|
||||
|
||||
private CallResolverUtil() {}
|
||||
|
||||
public static <D extends CallableDescriptor> ResolvedCallImpl<D> copy(@NotNull ResolvedCallImpl<D> call, @NotNull CallResolutionContext<?> context) {
|
||||
public static <D extends CallableDescriptor> ResolvedCallImpl<D> copy(@NotNull ResolvedCallImpl<D> call) {
|
||||
ResolutionCandidate<D> candidate = ResolutionCandidate.create(call.getCandidateDescriptor(), call.getThisObject(),
|
||||
call.getReceiverArgument(), call.getExplicitReceiverKind(),
|
||||
call.isSafeCall());
|
||||
|
||||
ResolvedCallImpl<D> copy = ResolvedCallImpl.create(candidate, TraceUtil.DELEGATING_TRACE_STUB, call.getTracing(), call.getDataFlowInfoForArguments());
|
||||
context.trace.record(BindingContext.RESOLVED_CALL, context.call.getCalleeExpression(), copy);
|
||||
ResolvedCallImpl<D> copy = ResolvedCallImpl.create(
|
||||
candidate, TraceUtil.DELEGATING_TRACE_STUB, call.getTracing(), call.getDataFlowInfoForArguments());
|
||||
|
||||
copy.addStatus(call.getStatus());
|
||||
if (call.isDirty()) {
|
||||
|
||||
Reference in New Issue
Block a user