@@ -10,11 +10,11 @@ import org.jetbrains.kotlin.descriptors.*
1010import org.jetbrains.kotlin.descriptors.annotations.AnnotationDescriptor
1111import org.jetbrains.kotlin.descriptors.annotations.AnnotationDescriptorImpl
1212import org.jetbrains.kotlin.descriptors.annotations.Annotations
13- import org.jetbrains.kotlin.js.descriptorUtils.getJetTypeFqName
13+ import org.jetbrains.kotlin.js.descriptorUtils.getKotlinTypeFqName
1414import org.jetbrains.kotlin.name.ClassId
1515import org.jetbrains.kotlin.name.Name
1616import org.jetbrains.kotlin.platform.isCommon
17- import org.jetbrains.kotlin.platform.js. isJs
17+ import org.jetbrains.kotlin.platform.isJs
1818import org.jetbrains.kotlin.platform.jvm.isJvm
1919import org.jetbrains.kotlin.resolve.BindingContext
2020import org.jetbrains.kotlin.resolve.constants.ArrayValue
@@ -193,19 +193,13 @@ open class SuspendTransformSyntheticResolveExtension(open val configuration: Sus
193193
194194 fun check (): Boolean {
195195 val platform = classDescriptor.platform
196- if (platform.isJvm() && targetPlatform == TargetPlatform .JVM ) {
197- return true
198- }
199-
200- if (platform.isJs() && targetPlatform == TargetPlatform .JS ) {
201- return true
202- }
203196
204- if (platform.isCommon() && targetPlatform == TargetPlatform .COMMON ) {
205- return true
197+ return when {
198+ platform.isJvm() && targetPlatform == TargetPlatform .JVM -> true
199+ platform.isJs() && targetPlatform == TargetPlatform .JS -> true
200+ platform.isCommon() && targetPlatform == TargetPlatform .COMMON -> true
201+ else -> false
206202 }
207-
208- return false
209203 }
210204
211205 platform.isCommon()
@@ -318,9 +312,10 @@ private fun SimpleFunctionDescriptor.toGeneratedByDescriptorInfo(): List<StringV
318312 add(d.name.sv)
319313 d.allParameters.forEach {
320314 add(it.name.sv)
321- add(it.type.getJetTypeFqName(true ).sv)
315+ // add(it.type.getJetTypeFqName(true).sv)
316+ add(it.type.getKotlinTypeFqName(true ).sv)
322317 }
323- add(d.returnType?.getJetTypeFqName (true )?.sv ? : " ?" .sv)
318+ add(d.returnType?.getKotlinTypeFqName (true )?.sv ? : " ?" .sv)
324319 }
325320
326321}
0 commit comments