From f4c5f5d8eb51be06340f267822b726b278ab83ae Mon Sep 17 00:00:00 2001 From: Vladimir Sukharev Date: Mon, 15 Aug 2022 15:11:52 +0000 Subject: [PATCH] Fix filecheck for Objective-C targets Merge-request: KT-MR-6854 Merged-by: Vladimir Sukharev --- kotlin-native/backend.native/tests/build.gradle | 4 ++-- .../tests/filecheck/kt53261/kt53261_inline_unbox.kt | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/kotlin-native/backend.native/tests/build.gradle b/kotlin-native/backend.native/tests/build.gradle index de0bcc6ed1b..78c44c5164c 100644 --- a/kotlin-native/backend.native/tests/build.gradle +++ b/kotlin-native/backend.native/tests/build.gradle @@ -6232,8 +6232,8 @@ fileCheckTest("filecheck_kt49847_generic_receiver") { fileCheckTest("filecheck_kt53261_inline_unbox") { annotatedSource = project.file('filecheck/kt53261/kt53261_inline_unbox.kt') enabled = project.globalTestArgs.contains('-opt') - if (target.architecture == Architecture.ARM64) { - checkPrefix = "CHECK-ARM64" + if (isAppleTarget(project)) { + checkPrefix = "CHECK-APPLE" } } diff --git a/kotlin-native/backend.native/tests/filecheck/kt53261/kt53261_inline_unbox.kt b/kotlin-native/backend.native/tests/filecheck/kt53261/kt53261_inline_unbox.kt index 2bee9b3d99c..e0599425cae 100644 --- a/kotlin-native/backend.native/tests/filecheck/kt53261/kt53261_inline_unbox.kt +++ b/kotlin-native/backend.native/tests/filecheck/kt53261/kt53261_inline_unbox.kt @@ -30,5 +30,5 @@ fun main(arr: Array) { // CHECK-NOT: {{call|invoke}} <4 x float> @"kfun:kotlin.native# // CHECK-NOT: {{call|invoke}} %struct.ObjHeader* @"kfun:kotlin# -// On ARM64, generated functions IntToNSNumber and UIntToNSNumber may contain non-converted invocations of unbox functions. -// CHECK-ARM64: IntToNSNumber +// On APPLE targets, generated functions ToNSNumber may contain non-converted invocations of unbox functions. +// CHECK-APPLE: {{IntToNSNumber|LongToNSNumber|ByteToNSNumber|ShortToNSNumber|FloatToNSNumber|DoubleToNSNumber}}