Strip semicolons; Make odin strip-semicolon replace .. with ..= if used as a binary operator

This commit is contained in:
gingerBill
2021-09-06 20:15:59 +01:00
parent 3bf005bfc5
commit 0434281f73
21 changed files with 999 additions and 968 deletions
+21 -21
View File
@@ -8,36 +8,36 @@ when ODIN_OS == "windows" {
foreign import libc "system:c"
}
sig_atomic_t :: distinct atomic_int;
sig_atomic_t :: distinct atomic_int
@(default_calling_convention="c")
foreign libc {
signal :: proc(sig: int, func: proc "c" (int)) -> proc "c" (int) ---;
raise :: proc(sig: int) -> int ---;
signal :: proc(sig: int, func: proc "c" (int)) -> proc "c" (int) ---
raise :: proc(sig: int) -> int ---
}
when ODIN_OS == "windows" {
SIG_ERR :: rawptr(~uintptr(0));
SIG_DFL :: rawptr(uintptr(0));
SIG_IGN :: rawptr(uintptr(1));
SIG_ERR :: rawptr(~uintptr(0))
SIG_DFL :: rawptr(uintptr(0))
SIG_IGN :: rawptr(uintptr(1))
SIGABRT :: 22;
SIGFPE :: 8;
SIGILL :: 4;
SIGINT :: 2;
SIGSEGV :: 11;
SIGTERM :: 15;
SIGABRT :: 22
SIGFPE :: 8
SIGILL :: 4
SIGINT :: 2
SIGSEGV :: 11
SIGTERM :: 15
}
when ODIN_OS == "linux" || ODIN_OS == "freebsd" || ODIN_OS == "darwin" {
SIG_ERR :: rawptr(~uintptr(0));
SIG_DFL :: rawptr(uintptr(0));
SIG_IGN :: rawptr(uintptr(1));
SIG_ERR :: rawptr(~uintptr(0))
SIG_DFL :: rawptr(uintptr(0))
SIG_IGN :: rawptr(uintptr(1))
SIGABRT :: 6;
SIGFPE :: 8;
SIGILL :: 4;
SIGINT :: 2;
SIGSEGV :: 11;
SIGTERM :: 15;
SIGABRT :: 6
SIGFPE :: 8
SIGILL :: 4
SIGINT :: 2
SIGSEGV :: 11
SIGTERM :: 15
}