Hi everyone, does anyone know how to access the da...
# kotlin-native
m
Hi everyone, does anyone know how to access the data classes of Kotlin native in native c code? The header files generated by kotlin native is very complex and I am not able to decode it. example : listof() in kotlin native becomes libnative_kref_kotlin_collections_List as shown below
Copy code
typedef struct {
  libnative_KNativePtr pinned;
} libnative_kref_kotlin_collections_List;
I can access libnative_kref_kotlin_collections_List in my c code by including the header but I am not sure on how I can pass listOf strings to this. Is there any documentation around how to access and use the data classes from Kotlin native in c code? I am trying to write something like below in my c code : vector<string>recentTasksV; recentTasksV.push_back("hello"); libnative_kref_kotlin_collections_List recentTasks = libnative_kref_kotlin_collections_List(recentTasksV) ;