[FIR IDE] Extract implicit set parameter name to reuse it in Analysis API
This commit is contained in:
committed by
teamcityserver
parent
2b8963455f
commit
44a1fe668e
@@ -58,6 +58,9 @@ object SpecialNames {
|
||||
@JvmField
|
||||
val UNDERSCORE_FOR_UNUSED_VAR = Name.special("<unused var>")
|
||||
|
||||
@JvmField
|
||||
val IMPLICIT_SET_PARAMETER = Name.special("<set-?>")
|
||||
|
||||
@JvmStatic
|
||||
fun safeIdentifier(name: Name?): Name {
|
||||
return if (name != null && !name.isSpecial) name else SAFE_IDENTIFIER_FOR_NO_NAME
|
||||
|
||||
+2
-1
@@ -21,6 +21,7 @@ import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.kotlin.descriptors.*;
|
||||
import org.jetbrains.kotlin.descriptors.annotations.Annotations;
|
||||
import org.jetbrains.kotlin.name.Name;
|
||||
import org.jetbrains.kotlin.name.SpecialNames;
|
||||
import org.jetbrains.kotlin.types.KotlinType;
|
||||
|
||||
import java.util.Collection;
|
||||
@@ -67,7 +68,7 @@ public class PropertySetterDescriptorImpl extends PropertyAccessorDescriptorImpl
|
||||
@NotNull Annotations annotations
|
||||
) {
|
||||
return new ValueParameterDescriptorImpl(
|
||||
setterDescriptor, null, 0, annotations, Name.special("<set-?>"), type,
|
||||
setterDescriptor, null, 0, annotations, SpecialNames.IMPLICIT_SET_PARAMETER, type,
|
||||
/* declaresDefaultValue = */ false,
|
||||
/* isCrossinline = */ false,
|
||||
/* isNoinline = */ false,
|
||||
|
||||
Reference in New Issue
Block a user