Runtime ABI (#1097)
This commit is contained in:
@@ -704,6 +704,10 @@ char* CreateCStringFromString(KConstRef kref) {
|
||||
return result;
|
||||
}
|
||||
|
||||
void DisposeCString(char* cstring) {
|
||||
if (cstring) konan::free(cstring);
|
||||
}
|
||||
|
||||
// String.kt
|
||||
KInt Kotlin_String_compareTo(KString thiz, KString other) {
|
||||
int result = memcmp(
|
||||
|
||||
@@ -29,6 +29,7 @@ extern "C" {
|
||||
OBJ_GETTER(CreateStringFromCString, const char* cstring);
|
||||
OBJ_GETTER(CreateStringFromUtf8, const char* utf8, uint32_t size);
|
||||
char* CreateCStringFromString(KConstRef kstring);
|
||||
void DisposeCString(char* cstring);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
@@ -391,7 +391,7 @@ bool ClearSubgraphReferences(ObjHeader* root, bool checked) RUNTIME_NOTHROW;
|
||||
// Creates stable pointer out of the object.
|
||||
void* CreateStablePointer(ObjHeader* obj) RUNTIME_NOTHROW;
|
||||
// Disposes stable pointer to the object.
|
||||
void DisposeStablePointer(void* pointer) RUNTIME_NOTHROW;;
|
||||
void DisposeStablePointer(void* pointer) RUNTIME_NOTHROW;
|
||||
// Translate stable pointer to object reference.
|
||||
OBJ_GETTER(DerefStablePointer, void*) RUNTIME_NOTHROW;
|
||||
// Move stable pointer ownership.
|
||||
|
||||
Reference in New Issue
Block a user