Drop 'propertyDelegated' convention (without additional deprecation ceremony).

This commit is contained in:
Dmitry Petrov
2016-12-06 15:35:23 +03:00
committed by Stanislav Erokhin
parent 5ddf8e60e6
commit e2b6d2d849
25 changed files with 8 additions and 300 deletions
@@ -4086,7 +4086,6 @@ public class ExpressionCodegen extends KtVisitor<StackValue, StackValue> impleme
if (isDelegatedLocalVariable(variableDescriptor)) {
StackValue metadataValue = getVariableMetadataValue(variableDescriptor);
initializePropertyMetadata((KtProperty) variableDeclaration, variableDescriptor, metadataValue);
invokePropertyDelegatedOnLocalVar(variableDescriptor, storeTo, metadataValue);
}
}
@@ -4097,19 +4096,6 @@ public class ExpressionCodegen extends KtVisitor<StackValue, StackValue> impleme
return descriptor;
}
private void invokePropertyDelegatedOnLocalVar(
@NotNull LocalVariableDescriptor variableDescriptor,
@NotNull StackValue delegateValue,
@NotNull StackValue metadataValue
) {
ResolvedCall<FunctionDescriptor> pdResolvedCall =
bindingContext.get(BindingContext.DELEGATED_PROPERTY_PD_RESOLVED_CALL, variableDescriptor);
if (pdResolvedCall == null) return;
tempVariables.put(pdResolvedCall.getCall().getValueArguments().get(0).asElement(), metadataValue);
invokeFunction(pdResolvedCall, delegateValue).put(Type.VOID_TYPE, v);
}
private void initializePropertyMetadata(
@NotNull KtProperty variable,
@NotNull LocalVariableDescriptor variableDescriptor,