From dd3de8372f947f2352ae29b1e9f74b7c19710930 Mon Sep 17 00:00:00 2001 From: Denis Zharkov Date: Wed, 1 Jun 2016 12:13:38 +0300 Subject: [PATCH] Minor. Cleanup FunctionDescriptorImpl --- .../descriptors/impl/FunctionDescriptorImpl.java | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/core/descriptors/src/org/jetbrains/kotlin/descriptors/impl/FunctionDescriptorImpl.java b/core/descriptors/src/org/jetbrains/kotlin/descriptors/impl/FunctionDescriptorImpl.java index 42f6417a3e6..e58c43b988b 100644 --- a/core/descriptors/src/org/jetbrains/kotlin/descriptors/impl/FunctionDescriptorImpl.java +++ b/core/descriptors/src/org/jetbrains/kotlin/descriptors/impl/FunctionDescriptorImpl.java @@ -329,17 +329,17 @@ public abstract class FunctionDescriptorImpl extends DeclarationDescriptorNonRoo protected @NotNull Kind kind; protected @NotNull List newValueParameterDescriptors; protected @Nullable KotlinType newExtensionReceiverParameterType; - protected @Nullable ReceiverParameterDescriptor dispatchReceiverParameter; + protected @Nullable ReceiverParameterDescriptor dispatchReceiverParameter = FunctionDescriptorImpl.this.dispatchReceiverParameter; protected @NotNull KotlinType newReturnType; protected @Nullable Name name; protected boolean copyOverrides = true; protected boolean signatureChange = false; protected boolean preserveSourceElement = false; protected boolean dropOriginalInContainingParts = false; - private boolean isHiddenToOvercomeSignatureClash; + private boolean isHiddenToOvercomeSignatureClash = isHiddenToOvercomeSignatureClash(); private List newTypeParameters = null; private Annotations additionalAnnotations = null; - private boolean isHiddenForResolutionEverywhereBesideSupercalls; + private boolean isHiddenForResolutionEverywhereBesideSupercalls = isHiddenForResolutionEverywhereBesideSupercalls(); private SourceElement sourceElement; public CopyConfiguration( @@ -360,11 +360,8 @@ public abstract class FunctionDescriptorImpl extends DeclarationDescriptorNonRoo this.kind = kind; this.newValueParameterDescriptors = newValueParameterDescriptors; this.newExtensionReceiverParameterType = newExtensionReceiverParameterType; - this.dispatchReceiverParameter = FunctionDescriptorImpl.this.dispatchReceiverParameter; this.newReturnType = newReturnType; this.name = name; - this.isHiddenToOvercomeSignatureClash = isHiddenToOvercomeSignatureClash(); - this.isHiddenForResolutionEverywhereBesideSupercalls = isHiddenForResolutionEverywhereBesideSupercalls(); } @Override @@ -724,7 +721,7 @@ public abstract class FunctionDescriptorImpl extends DeclarationDescriptorNonRoo return initialSignatureDescriptor; } - public void setInitialSignatureDescriptor(@Nullable FunctionDescriptor initialSignatureDescriptor) { + private void setInitialSignatureDescriptor(@Nullable FunctionDescriptor initialSignatureDescriptor) { this.initialSignatureDescriptor = initialSignatureDescriptor; } }