Do not suggest "create abstract property" inside annotation
This commit is contained in:
+2
-3
@@ -149,10 +149,9 @@ sealed class CreateCallableFromCallActionFactory<E : KtExpression>(
|
||||
if (originalReceiverTypeInfo !is TypeInfo.ByType) return null
|
||||
receiverTypeInfo = originalReceiverTypeInfo
|
||||
receiverType = receiverTypeInfo.theType
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
val containingClass = originalExpression.getStrictParentOfType<KtClassOrObject>() as? KtClass ?: return null
|
||||
if (containingClass is KtEnumEntry) return null
|
||||
if (containingClass is KtEnumEntry || containingClass.isAnnotation()) return null
|
||||
receiverType = (containingClass.unsafeResolveToDescriptor() as ClassDescriptor).defaultType
|
||||
receiverTypeInfo = TypeInfo(receiverType, Variance.IN_VARIANCE).ofThis()
|
||||
}
|
||||
|
||||
-1
@@ -1,5 +1,4 @@
|
||||
// "Create local variable 'defaultPreferencesName'" "false"
|
||||
// ACTION: Create abstract property 'defaultPreferencesName'
|
||||
// ACTION: Create parameter 'defaultPreferencesName'
|
||||
// ACTION: Create property 'defaultPreferencesName'
|
||||
// ACTION: Rename reference
|
||||
|
||||
Reference in New Issue
Block a user