[K/N] Debug util for checking if object is global constant
This commit is contained in:
@@ -378,4 +378,9 @@ KBoolean Kotlin_Debugging_isThreadStateNative() {
|
|||||||
return kotlin::GetThreadState() == kotlin::ThreadState::kNative;
|
return kotlin::GetThreadState() == kotlin::ThreadState::kNative;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
KBoolean Kotlin_Debugging_isPermanent(KRef obj) {
|
||||||
|
return obj->permanent();
|
||||||
|
}
|
||||||
|
|
||||||
} // extern "C"
|
} // extern "C"
|
||||||
|
|||||||
@@ -16,6 +16,10 @@ public object Debugging {
|
|||||||
get() = Debugging_isThreadStateRunnable()
|
get() = Debugging_isThreadStateRunnable()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GCUnsafeCall("Kotlin_Debugging_isPermanent")
|
||||||
|
@InternalForKotlinNative
|
||||||
|
public external fun Any.isPermanent() : Boolean
|
||||||
|
|
||||||
@GCUnsafeCall("Kotlin_Debugging_getForceCheckedShutdown")
|
@GCUnsafeCall("Kotlin_Debugging_getForceCheckedShutdown")
|
||||||
private external fun Debugging_getForceCheckedShutdown(): Boolean
|
private external fun Debugging_getForceCheckedShutdown(): Boolean
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user