Disallow extension properties with backing fields

#KT-1682 Fixed
This commit is contained in:
Alexander Udalov
2014-05-28 19:17:31 +04:00
parent ea31f372aa
commit d78d4bc44c
72 changed files with 297 additions and 578 deletions
@@ -50,28 +50,14 @@ public final class JvmAbi {
return fqName.lastSegmentIs(Name.identifier(CLASS_OBJECT_CLASS_NAME));
}
@NotNull
public static String getPropertyDelegateName(@NotNull Name name) {
return name.asString() + DELEGATED_PROPERTY_NAME_SUFFIX;
}
@NotNull
public static String getSyntheticMethodNameForAnnotatedProperty(@NotNull Name propertyName) {
return propertyName.asString() + ANNOTATED_PROPERTY_METHOD_NAME_SUFFIX;
}
@NotNull
public static String getDefaultPropertyName(@NotNull Name propertyName, boolean isDelegated, boolean isExtensionProperty) {
if (isDelegated) {
return getPropertyDelegateName(propertyName);
}
String name = propertyName.asString();
if (isExtensionProperty) {
name += "$ext";
}
return name;
public static String getDefaultFieldNameForProperty(@NotNull Name propertyName, boolean isDelegated) {
return isDelegated ? propertyName.asString() + DELEGATED_PROPERTY_NAME_SUFFIX : propertyName.asString();
}
private JvmAbi() {