aboutsummaryrefslogtreecommitdiff
path: root/core/runtime
diff options
context:
space:
mode:
authorgingerBill <gingerBill@users.noreply.github.com>2022-03-09 15:05:51 +0000
committergingerBill <gingerBill@users.noreply.github.com>2022-03-09 15:05:51 +0000
commit17eebf338c7c2428db99470f8e1dd6c8d2f7ac0f (patch)
tree03304d3f40216263abe5376283df515d0417236c /core/runtime
parent8e4d6b3e5dde51fdd71a49b2bf703ae3428c1c21 (diff)
Fix #1606 (Call `runtime._cleanup_runtime_contextless()` for `os.exit`)
Diffstat (limited to 'core/runtime')
-rw-r--r--core/runtime/core.odin5
1 files changed, 5 insertions, 0 deletions
diff --git a/core/runtime/core.odin b/core/runtime/core.odin
index 8d315a238..08ca4c049 100644
--- a/core/runtime/core.odin
+++ b/core/runtime/core.odin
@@ -459,6 +459,11 @@ _cleanup_runtime :: proc() {
default_temp_allocator_destroy(&global_default_temp_allocator_data)
}
+_cleanup_runtime_contextless :: proc "contextless" () {
+ context = default_context()
+ _cleanup_runtime()
+}
+
/////////////////////////////
/////////////////////////////