Could we have a `sizeof` like method? I’m struggli...
# kotlin-native
n
Could we have a
sizeof
like method? I’m struggling with this part, because I must more or less guest the size in bytes of each type, i.e.
(vertices.size * 4).signExtend()
and their c counterpart would just
sizeof(vertices)
o
this operations doesn’t make sense on pure Kotlin types, and on interop types there’s
size
companion object property, i.e. `IntVar.size`: https://github.com/JetBrains/kotlin-native/blob/14f622dac2c1958e1dedb51e66590c8354b987ff/Interop/Runtime/src/main/kotlin/kotlinx/cinterop/Types.kt#L206
n
this indeed helps me a lot, thanks