ObjCExport: deprecate exporting data class componentN methods to Obj-C

The Objective-C methods for Kotlin data class componentN methods
shouldn't have been generated in the first place -- the corresponding
Kotlin methods are required to make the destructuring work in Kotlin,
and don't help in Objective-C or Swift.

Calling them manually from Objective-C or Swift doesn't make much sense.
So now we deprecate this, in order to remove these methods from
Objective-C header completely later.

^KT-42641
^KT-49516 Fixed
This commit is contained in:
Svyatoslav Scherbina
2022-02-11 06:55:47 +00:00
committed by Space
parent 4636f71076
commit ad72545647
6 changed files with 195 additions and 38 deletions
@@ -0,0 +1,16 @@
/*
* Copyright 2010-2022 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license
* that can be found in the LICENSE file.
*/
package dataClassComponentMethods
data class DataClassWithComponentMethods(val x: Int, val y: Int)
class RegularClassWithComponentMethods {
fun component1() = 3
fun component3() = 4
}
fun component1() = 5
fun component4() = 6