use of org.jetbrains.kotlin.resolve.calls.model.DataFlowInfoForArgumentsImpl in project kotlin by JetBrains.
the class BasicExpressionTypingVisitor method recordThisOrSuperCallInTraceAndCallExtension.
private void recordThisOrSuperCallInTraceAndCallExtension(ExpressionTypingContext context, ReceiverParameterDescriptor descriptor, KtExpression expression) {
BindingTrace trace = context.trace;
Call call = CallMaker.makeCall(expression, null, null, expression, Collections.<ValueArgument>emptyList());
ResolutionCandidate<ReceiverParameterDescriptor> resolutionCandidate = ResolutionCandidate.create(call, descriptor, null, ExplicitReceiverKind.NO_EXPLICIT_RECEIVER, null);
ResolvedCallImpl<ReceiverParameterDescriptor> resolvedCall = ResolvedCallImpl.create(resolutionCandidate, TemporaryBindingTrace.create(trace, "Fake trace for fake 'this' or 'super' resolved call"), TracingStrategy.EMPTY, new DataFlowInfoForArgumentsImpl(context.dataFlowInfo, call));
resolvedCall.markCallAsCompleted();
trace.record(RESOLVED_CALL, call, resolvedCall);
trace.record(CALL, expression, call);
if (context.trace.wantsDiagnostics()) {
CallCheckerContext callCheckerContext = new CallCheckerContext(context, components.languageVersionSettings);
for (CallChecker checker : components.callCheckers) {
checker.check(resolvedCall, expression, callCheckerContext);
}
}
}
use of org.jetbrains.kotlin.resolve.calls.model.DataFlowInfoForArgumentsImpl in project kotlin by JetBrains.
the class BasicExpressionTypingVisitor method checkPropertySetterCall.
private void checkPropertySetterCall(@NotNull ExpressionTypingContext context, @NotNull PropertySetterDescriptor descriptor, @NotNull ResolvedCall<?> propertyResolvedCall, @NotNull KtExpression expression) {
Call call = propertyResolvedCall.getCall();
ResolutionCandidate<PropertySetterDescriptor> resolutionCandidate = ResolutionCandidate.create(call, descriptor, propertyResolvedCall.getDispatchReceiver(), propertyResolvedCall.getExplicitReceiverKind(), null);
ResolvedCallImpl<PropertySetterDescriptor> resolvedCall = ResolvedCallImpl.create(resolutionCandidate, TemporaryBindingTrace.create(context.trace, "Trace for fake property setter resolved call"), TracingStrategy.EMPTY, new DataFlowInfoForArgumentsImpl(propertyResolvedCall.getDataFlowInfoForArguments().getResultInfo(), call));
resolvedCall.markCallAsCompleted();
if (context.trace.wantsDiagnostics()) {
CallCheckerContext callCheckerContext = new CallCheckerContext(context, components.languageVersionSettings);
for (CallChecker checker : components.callCheckers) {
checker.check(resolvedCall, expression, callCheckerContext);
}
}
}
Aggregations