Rename: getModuleDescriptorForElement -> findModuleDescriptor
This commit is contained in:
+1
-1
@@ -53,7 +53,7 @@ public class KotlinCacheService(val project: Project) {
|
||||
return cache.getLazyResolveSession(element).resolveToElement(element)
|
||||
}
|
||||
|
||||
override fun getModuleDescriptorForElement(element: JetElement): ModuleDescriptor {
|
||||
override fun findModuleDescriptor(element: JetElement): ModuleDescriptor {
|
||||
return cache.getLazyResolveSession(element).getModuleDescriptor()
|
||||
}
|
||||
|
||||
|
||||
@@ -28,5 +28,5 @@ public trait ResolutionFacade {
|
||||
|
||||
public fun resolveToDescriptor(declaration: JetDeclaration): DeclarationDescriptor
|
||||
|
||||
public fun getModuleDescriptorForElement(element: JetElement): ModuleDescriptor
|
||||
public fun findModuleDescriptor(element: JetElement): ModuleDescriptor
|
||||
}
|
||||
|
||||
@@ -36,8 +36,8 @@ public fun JetElement.analyze(): BindingContext {
|
||||
return getLazyResolveSession().analyze(this)
|
||||
}
|
||||
|
||||
public fun JetElement.getModuleDescriptorForElement(): ModuleDescriptor {
|
||||
return getLazyResolveSession().getModuleDescriptorForElement(this)
|
||||
public fun JetElement.findModuleDescriptor(): ModuleDescriptor {
|
||||
return getLazyResolveSession().findModuleDescriptor(this)
|
||||
}
|
||||
|
||||
public fun JetElement.getAnalysisResults(vararg extraFiles: JetFile): AnalysisResult {
|
||||
|
||||
+2
-2
@@ -35,7 +35,7 @@ import org.jetbrains.jet.lang.resolve.calls.callUtil.getResolvedCall
|
||||
import org.jetbrains.jet.lang.psi.psiUtil.getTextWithLocation
|
||||
import org.jetbrains.jet.lang.resolve.bindingContextUtil.getDataFlowInfo
|
||||
import org.jetbrains.jet.plugin.util.approximateFlexibleTypes
|
||||
import org.jetbrains.jet.plugin.caches.resolve.getModuleDescriptorForElement
|
||||
import org.jetbrains.jet.plugin.caches.resolve.findModuleDescriptor
|
||||
|
||||
public class RemoveExplicitTypeArguments : JetSelfTargetingIntention<JetTypeArgumentList>(
|
||||
"remove.explicit.type.arguments", javaClass()) {
|
||||
@@ -47,7 +47,7 @@ public class RemoveExplicitTypeArguments : JetSelfTargetingIntention<JetTypeArgu
|
||||
val context = AnalyzerFacadeWithCache.getContextForElement(callExpression)
|
||||
if (callExpression.getTypeArguments().isEmpty()) return false
|
||||
|
||||
val injector = InjectorForMacros(callExpression.getProject(), callExpression.getModuleDescriptorForElement())
|
||||
val injector = InjectorForMacros(callExpression.getProject(), callExpression.findModuleDescriptor())
|
||||
|
||||
val scope = context[BindingContext.RESOLUTION_SCOPE, callExpression]
|
||||
val originalCall = callExpression.getResolvedCall(context)
|
||||
|
||||
Reference in New Issue
Block a user