aboutsummaryrefslogtreecommitdiff
path: root/core/os/env_js.odin
diff options
context:
space:
mode:
authorJeroen van Rijn <Kelimion@users.noreply.github.com>2026-02-12 12:02:11 +0100
committerJeroen van Rijn <Kelimion@users.noreply.github.com>2026-02-12 12:12:21 +0100
commit658e6b9d9fabe0b249f552257fe8918b010003b0 (patch)
treeb3e66caa49222e878e5c4a6124433a6513a069d4 /core/os/env_js.odin
parent97683ae0146e6668d56e701c1d54a4e1737e41c8 (diff)
Add `core:log` support for js/wasm
Also add #panic when importing `core:os` on wasm.
Diffstat (limited to 'core/os/env_js.odin')
-rw-r--r--core/os/env_js.odin10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/os/env_js.odin b/core/os/env_js.odin
index 644af61bd..55ffce593 100644
--- a/core/os/env_js.odin
+++ b/core/os/env_js.odin
@@ -2,16 +2,16 @@
#+private
package os
+// None of this does anything on js/wasm.
+// It's only here so importing `core:os` on wasm panics cleanly,
+// without spamming about all sorts of missing procs and types.
+
import "base:runtime"
build_env :: proc() -> (err: Error) {
return
}
-// delete_string_if_not_original :: proc(str: string) {
-
-// }
-
@(require_results)
_lookup_env_alloc :: proc(key: string, allocator: runtime.Allocator) -> (value: string, found: bool) {
return
@@ -39,4 +39,4 @@ _clear_env :: proc() {
@(require_results)
_environ :: proc(allocator: runtime.Allocator) -> (environ: []string, err: Error) {
return {}, .Unsupported
-}
+} \ No newline at end of file