Fixed ReplaceWith quickfix not working when synthetic extensions are used in the pattern

This commit is contained in:
Valentin Kipyatkov
2015-09-01 15:51:19 +03:00
parent 16650e8f5c
commit 37ed77467f
8 changed files with 46 additions and 22 deletions
@@ -29,7 +29,7 @@ public interface FileScopeProvider {
}
public interface AdditionalScopes {
public fun scopes(file: JetFile): List<JetScope>
public val scopes: List<JetScope>
}
}
@@ -80,7 +80,7 @@ public class FileScopeProviderImpl(
scopeChain.add(LazyImportScope(packageFragment, allUnderImportResolver, LazyImportScope.FilteringKind.VISIBLE_CLASSES, "All under imports in $debugName (visible classes)"))
scopeChain.add(LazyImportScope(packageFragment, defaultAllUnderImportResolver, LazyImportScope.FilteringKind.VISIBLE_CLASSES, "Default all under imports in $debugName (visible classes)"))
scopeChain.addAll(additionalScopes.flatMap { it.scopes(file) })
scopeChain.addAll(additionalScopes.flatMap { it.scopes })
scopeChain.add(LazyImportScope(packageFragment, allUnderImportResolver, LazyImportScope.FilteringKind.INVISIBLE_CLASSES, "All under imports in $debugName (invisible classes only)"))
scopeChain.add(LazyImportScope(packageFragment, defaultAllUnderImportResolver, LazyImportScope.FilteringKind.INVISIBLE_CLASSES, "Default all under imports in $debugName (invisible classes only)"))