More elegant way to achieve the same + fixed KT-7746 Top level package name completion does not work inside class body

#KT-7746 Fixed
This commit is contained in:
Valentin Kipyatkov
2015-07-16 00:41:54 +03:00
parent 82c9cd790e
commit c1b2ea0b48
7 changed files with 34 additions and 8 deletions
@@ -221,9 +221,7 @@ public class ReferenceVariantsHelper(
nameFilter: (Name) -> Boolean
) {
if (kindFilter.excludes.contains(DescriptorKindExclude.Extensions)) return
val extensionsFilter = kindFilter
.restrictedToKinds(DescriptorKindFilter.FUNCTIONS_MASK or DescriptorKindFilter.VARIABLES_MASK)
.exclude(DescriptorKindExclude.NonExtensions)
val extensionsFilter = kindFilter.exclude(DescriptorKindExclude.NonExtensions)
fun processExtension(descriptor: DeclarationDescriptor) {
addAll((descriptor as CallableDescriptor).substituteExtensionIfCallable(receiver, callType, context, dataFlowInfo, resolutionScope.getContainingDeclaration()))