JS: make functions called call to inline properly. See KT-7004

This commit is contained in:
Alexey Andreev
2017-01-11 12:17:32 +03:00
parent 10a3fbf53f
commit 2907eafa18
8 changed files with 129 additions and 7 deletions
@@ -20,6 +20,7 @@ package org.jetbrains.kotlin.js.backend.ast.metadata
import com.intellij.psi.PsiElement
import org.jetbrains.kotlin.descriptors.CallableDescriptor
import org.jetbrains.kotlin.descriptors.DeclarationDescriptor
import org.jetbrains.kotlin.descriptors.FunctionDescriptor
import org.jetbrains.kotlin.js.backend.ast.*
import org.jetbrains.kotlin.resolve.inline.InlineStrategy
@@ -27,6 +28,8 @@ import org.jetbrains.kotlin.types.KotlinType
var JsName.staticRef: JsNode? by MetadataProperty(default = null)
var JsName.descriptor: DeclarationDescriptor? by MetadataProperty(default = null)
// TODO: move this to module 'js.inliner' and change dependency on 'frontend' to dependency on 'descriptors'
var JsInvocation.inlineStrategy: InlineStrategy? by MetadataProperty(default = null)