Files
Odin/core/runtime/os_specific_any.odin
Yawning Angel 29c80c238d core: Fixed build constraints
Multiple constraints on the same line are combined with logical OR,
while combining multiple negated constraints needs to be done with
logical AND (each constraint on a separate line).
2023-12-17 23:02:46 +09:00

17 lines
432 B
Odin

//+build !darwin
//+build !freestanding
//+build !js
//+build !wasi
//+build !windows
package runtime
import "core:os"
// TODO(bill): reimplement `os.write` so that it does not rely on package os
// NOTE: Use os_specific_linux.odin, os_specific_darwin.odin, etc
_os_write :: proc "contextless" (data: []byte) -> (int, _OS_Errno) {
context = default_context()
n, err := os.write(os.stderr, data)
return int(n), _OS_Errno(err)
}