I don’t think you can do this, because the T of MyClass is erased at compile time, isn’t it? What benefit is reification giving you in your suspend fn?
f
Fail
07/12/2019, 1:14 PM
Suspended function is not my. It fn of ktor class. I want to write wrapper
a
alex.hart
07/12/2019, 1:25 PM
have you considered reifing and inlining getData? I think as it stands now, you’ll not be able to get around the erasure… I could be wrong though.
b
Benjamin Charais
07/12/2019, 8:20 PM
unless you could have your T resolved with a type check, you will be forced into inline/reify the function itself.