hasSynthesizedParameterNames() pulled up into CallableDescriptor
This commit is contained in:
-1
@@ -19,5 +19,4 @@ package org.jetbrains.jet.lang.resolve.java.descriptor;
|
||||
import org.jetbrains.jet.lang.descriptors.CallableMemberDescriptor;
|
||||
|
||||
public interface JavaCallableMemberDescriptor extends CallableMemberDescriptor {
|
||||
boolean hasSynthesizedParameterNames();
|
||||
}
|
||||
|
||||
@@ -51,8 +51,19 @@ public interface CallableDescriptor extends DeclarationDescriptorWithVisibility,
|
||||
@NotNull
|
||||
List<ValueParameterDescriptor> getValueParameters();
|
||||
|
||||
/**
|
||||
* Kotlin functions always have stable parameter names that can be reliably used when calling them with named arguments.
|
||||
* Functions loaded from platform definitions (e.g. Java binaries or JS) may have unstable parameter names that vary from
|
||||
* one platform installation to another. These names can not be used reliably for calls with named arguments.
|
||||
*/
|
||||
boolean hasStableParameterNames();
|
||||
|
||||
/**
|
||||
* Sometimes parameter names are not available at all (e.g. Java binaries with not enough debug information).
|
||||
* In this case, getName() returns synthetic names such as "p0", "p1" etc.
|
||||
*/
|
||||
boolean hasSynthesizedParameterNames();
|
||||
|
||||
// Workaround for KT-4609 Wildcard types (super/extends) shouldn't be loaded as nullable
|
||||
@KotlinSignature("fun getOverriddenDescriptors(): Set<out CallableDescriptor>")
|
||||
@NotNull
|
||||
|
||||
+5
@@ -87,6 +87,11 @@ public abstract class AbstractReceiverParameterDescriptor extends DeclarationDes
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasSynthesizedParameterNames() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public Set<? extends CallableDescriptor> getOverriddenDescriptors() {
|
||||
|
||||
+5
@@ -159,6 +159,11 @@ public abstract class FunctionDescriptorImpl extends DeclarationDescriptorNonRoo
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasSynthesizedParameterNames() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public JetType getReturnType() {
|
||||
return unsubstitutedReturnType;
|
||||
|
||||
+5
@@ -89,6 +89,11 @@ public abstract class PropertyAccessorDescriptorImpl extends DeclarationDescript
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasSynthesizedParameterNames() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public Modality getModality() {
|
||||
|
||||
+5
@@ -85,6 +85,11 @@ public abstract class VariableDescriptorImpl extends DeclarationDescriptorNonRoo
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasSynthesizedParameterNames() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public Set<? extends CallableDescriptor> getOverriddenDescriptors() {
|
||||
|
||||
Reference in New Issue
Block a user