Devirtualize calls to PackageFragmentDescriptorImpl.fqName
1. Replace INVOKEINTERFACE with INVOKEVIRTUAL 2. Make callee function final It helps to decrease one module compilation time by 1-2 seconds
This commit is contained in:
+1
-1
@@ -23,7 +23,7 @@ import org.jetbrains.kotlin.types.TypeSubstitutor
|
||||
|
||||
abstract class PackageFragmentDescriptorImpl(
|
||||
module: ModuleDescriptor,
|
||||
override val fqName: FqName
|
||||
final override val fqName: FqName
|
||||
) : DeclarationDescriptorNonRootImpl(module, Annotations.EMPTY, fqName.shortNameOrSpecial(), SourceElement.NO_SOURCE),
|
||||
PackageFragmentDescriptor {
|
||||
override fun substitute(substitutor: TypeSubstitutor): DeclarationDescriptor? = this
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ import org.jetbrains.kotlin.types.TypeSubstitutor
|
||||
import org.jetbrains.kotlin.types.error.MissingDependencyErrorClass
|
||||
import org.jetbrains.kotlin.utils.Printer
|
||||
|
||||
private class PackageFragmentWithMissingDependencies(override val fqName: FqName, moduleDescriptor: ModuleDescriptor) :
|
||||
private class PackageFragmentWithMissingDependencies(fqName: FqName, moduleDescriptor: ModuleDescriptor) :
|
||||
PackageFragmentDescriptorImpl(moduleDescriptor, fqName) {
|
||||
override fun getMemberScope(): MemberScope {
|
||||
return ScopeWithMissingDependencies(fqName, this)
|
||||
|
||||
Reference in New Issue
Block a user