Closed Cassio90 closed 8 months ago
https://skie.touchlab.co/features/suspend#generic-classes - We tried and couldn't find a way around this since we need to do extension X
, but if X
is generic Objective-C class, we can't extend it (we can but can't use the generic type). If you have specific types, you can do:
extension HttpResponse where T == String {
func body() async throws -> String {
return try await skie(self).body()
}
}
What is the problem?
coroutinesInterop
is enabled.Our issue is for example the
body()
function. It's contained in the .h file just fine:What we noticed is that when
coroutinesInterop.set(true)
theTSAPIHttpResponse
entry is completely missing from.apinotes
It's included with
coroutinesInterop.set(false)
:What versions of SKIE, Kotlin, and Gradle do you use?
Am I missing something & can I provide you anything else to investigate this? :)
Update: Noticed that this works:
skie(httpResponse).body()
Is there a way to get it working without this workaround?