mirror of
https://github.com/odin-lang/Odin.git
synced 2026-04-22 22:35:19 +00:00
Clean-up OS constants; Clean-up procs_wasm32.odin
This commit is contained in:
@@ -4,6 +4,11 @@ import "core:mem"
|
||||
import "core:strconv"
|
||||
import "core:unicode/utf8"
|
||||
|
||||
|
||||
OS :: ODIN_OS;
|
||||
ARCH :: ODIN_ARCH;
|
||||
ENDIAN :: ODIN_ENDIAN;
|
||||
|
||||
write_string :: proc(fd: Handle, str: string) -> (int, Errno) {
|
||||
return write(fd, transmute([]byte)str);
|
||||
}
|
||||
|
||||
@@ -1,4 +0,0 @@
|
||||
package os;
|
||||
|
||||
ARCH :: "x86";
|
||||
ENDIAN :: "little";
|
||||
@@ -1,4 +0,0 @@
|
||||
package os;
|
||||
|
||||
ARCH :: "amd64";
|
||||
ENDIAN :: "little";
|
||||
@@ -7,8 +7,6 @@ import "core:runtime"
|
||||
import "core:strings"
|
||||
import "core:c"
|
||||
|
||||
OS :: "darwin";
|
||||
|
||||
Handle :: distinct i32;
|
||||
File_Time :: distinct u64;
|
||||
Errno :: distinct int;
|
||||
|
||||
@@ -24,7 +24,7 @@ Textbox :: struct { using element : Element, };
|
||||
ListView :: struct { using element : Element, };
|
||||
NumericEntry :: struct { using element : Element, };
|
||||
Menu :: struct { using element : Element, };
|
||||
MenuCallbackFunction :: distinct #type proc (^Element, Generic);
|
||||
MenuCallbackFunction :: distinct #type proc (^Element, Generic);
|
||||
INSTANCE_TYPE :: Instance;
|
||||
SCANCODE_A :: (0x1C);
|
||||
SCANCODE_B :: (0x32);
|
||||
@@ -2436,5 +2436,3 @@ current_thread_id :: proc "contextless" () -> int {
|
||||
// return int(EsThreadGetID(ES_CURRENT_THREAD));
|
||||
return -1;
|
||||
}
|
||||
|
||||
OS :: "essence";
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
package os
|
||||
|
||||
OS :: "js";
|
||||
|
||||
|
||||
Handle :: distinct i32;
|
||||
Errno :: distinct i32;
|
||||
|
||||
|
||||
@@ -7,8 +7,6 @@ import "core:runtime"
|
||||
import "core:strings"
|
||||
import "core:c"
|
||||
|
||||
OS :: "linux";
|
||||
|
||||
Handle :: distinct i32;
|
||||
File_Time :: distinct u64;
|
||||
Errno :: distinct i32;
|
||||
|
||||
@@ -4,8 +4,6 @@ package os
|
||||
import win32 "core:sys/windows"
|
||||
import "core:intrinsics"
|
||||
|
||||
OS :: "windows";
|
||||
|
||||
Handle :: distinct uintptr;
|
||||
File_Time :: distinct u64;
|
||||
Errno :: distinct int;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
//+build wasm32
|
||||
package runtime
|
||||
|
||||
@(link_name="memset")
|
||||
|
||||
Reference in New Issue
Block a user