From 99026c869b5106c6819d6019e0de09d82ce9df19 Mon Sep 17 00:00:00 2001 From: Ilya Kirillov <ilya.kirillov@jetbrains.com> Date: Sun, 24 Jul 2022 19:53:30 +0200 Subject: [PATCH] [kotlin] fix IntroduceBackingPropertyIntention after https://github.com/JetBrains/kotlin/commit/8d79fab109f79fdb6272f73dcddbc472ac7a3af8 GitOrigin-RevId: fb05cf401c41e48043053725bd6f032674ac595d --- .../kotlin/idea/intentions/IntroduceBackingPropertyIntention.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/kotlin/idea/src/org/jetbrains/kotlin/idea/intentions/IntroduceBackingPropertyIntention.kt b/plugins/kotlin/idea/src/org/jetbrains/kotlin/idea/intentions/IntroduceBackingPropertyIntention.kt index 91a758986678..bd7be16aeac4 100644 --- a/plugins/kotlin/idea/src/org/jetbrains/kotlin/idea/intentions/IntroduceBackingPropertyIntention.kt +++ b/plugins/kotlin/idea/src/org/jetbrains/kotlin/idea/intentions/IntroduceBackingPropertyIntention.kt @@ -35,7 +35,7 @@ class IntroduceBackingPropertyIntention : SelfTargetingIntention<KtProperty>( val bindingContext = property.getResolutionFacade().analyzeWithAllCompilerChecks(property).bindingContext val descriptor = bindingContext.get(BindingContext.DECLARATION_TO_DESCRIPTOR, property) as? PropertyDescriptor ?: return false - if (bindingContext.get(BindingContext.BACKING_FIELD_REQUIRED, descriptor) == false) return false + if (bindingContext.get(BindingContext.BACKING_FIELD_REQUIRED, descriptor) != true) return false val containingClass = property.getStrictParentOfType<KtClassOrObject>() ?: return false if (containingClass.isExpectDeclaration()) return false -- GitLab