[FIR] Type "top-level classifier names in package" as Name
- This is more consistent with "top-level callable names in package" and simplifies the set construction quite a bit, as we can avoid a lot of `asString` conversions.
This commit is contained in:
committed by
Space Team
parent
8034d522b9
commit
efe587691b
+2
-2
@@ -79,9 +79,9 @@ class FirCloneableSymbolProvider(
|
||||
}
|
||||
|
||||
override val symbolNamesProvider: FirSymbolNamesProvider = object : FirSymbolNamesProviderWithoutCallables() {
|
||||
override fun getTopLevelClassifierNamesInPackage(packageFqName: FqName): Set<String> =
|
||||
override fun getTopLevelClassifierNamesInPackage(packageFqName: FqName): Set<Name> =
|
||||
if (packageFqName == StandardClassIds.Cloneable.packageFqName) {
|
||||
setOf(StandardClassIds.Cloneable.shortClassName.asString())
|
||||
setOf(StandardClassIds.Cloneable.shortClassName)
|
||||
} else emptySet()
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -85,8 +85,8 @@ class FirProviderImpl(val session: FirSession, val kotlinScopeProvider: FirKotli
|
||||
override fun getPackageNamesWithTopLevelCallables(): Set<String> =
|
||||
state.allSubPackages.mapTo(mutableSetOf()) { it.asString() }
|
||||
|
||||
override fun getTopLevelClassifierNamesInPackage(packageFqName: FqName): Set<String> =
|
||||
state.classifierInPackage[packageFqName].orEmpty().mapTo(mutableSetOf()) { it.asString() }
|
||||
override fun getTopLevelClassifierNamesInPackage(packageFqName: FqName): Set<Name> =
|
||||
state.classifierInPackage[packageFqName].orEmpty()
|
||||
|
||||
override fun getTopLevelCallableNamesInPackage(packageFqName: FqName): Set<Name> = buildSet {
|
||||
for (key in state.functionMap.keys) {
|
||||
|
||||
Reference in New Issue
Block a user