Need to disable the__attribute__((swift_name)) for the transpiled xcframework #87
Replies: 1 comment
-
Hi! I'm not sure I understand the question correctly, so let me first ask a couple of clarifying questions:
By 'transpile,' do you mean that you compiled the Kotlin code using the Kotlin native compiler? (Transpilation is usually used in the context of converting code written in one programming language into another, which is not what the Kotlin native compiler does as it produces a binary.)
In other words, after adding SKIE, did you notice that some Kotlin classes are named differently in Swift than you would expect? If so, I'm not aware that SKIE renames classes in the described way. Maybe it's a bug. Can you give me an example of some of those classes? |
Beta Was this translation helpful? Give feedback.
-
Hi Team,
Currently when we transpile kotlin code to xcframework we know that all the class names have the prefix with the module name which is added by kotlin compiler by default. But when we added the touchlab plugin dependency we saw that attribute((swift_name)) is generated for every class name which has that prefix removed from the class name.
So our requirement is we needed that prefix and the reason is when this transpiled xcframework is used in a different swift repo we have the same class names in the both existing swift repo and in the transpiled code(and we need both code bases i.e existing code and transpiled code) as well and we get the compilation error because of the name conflict. So we need that module name prefix to differentiate it from existing swift repo.
Can you please let me know if this can be achieved with some configuration flag or any other solution.
Beta Was this translation helpful? Give feedback.
All reactions