[Swift Export] Use ExportedBridge instead of ExportForCppRuntime
ExportedBridge annotation actually does what we need in Swift Export. Unlike ExportForCppRuntime, it prevents symbol from DCE.
This commit is contained in:
committed by
Space Team
parent
d83027720d
commit
01976990e8
@@ -1,12 +1,12 @@
|
||||
import kotlin.native.internal.ExportForCppRuntime
|
||||
import kotlin.native.internal.ExportedBridge
|
||||
|
||||
@ExportForCppRuntime("a_b_bar_bridge")
|
||||
@ExportedBridge("a_b_bar_bridge")
|
||||
public fun a_b_bar_bridge(param1: Int, param2: Long): Int {
|
||||
val result = a.b.bar(param1, param2)
|
||||
return result
|
||||
}
|
||||
|
||||
@ExportForCppRuntime("a_b_foo_bridge")
|
||||
@ExportedBridge("a_b_foo_bridge")
|
||||
public fun a_b_foo_bridge(param1: Int, param2: Long): Boolean {
|
||||
val result = a.b.foo(param1, param2)
|
||||
return result
|
||||
|
||||
Reference in New Issue
Block a user