From efab82784d14da5f4561cff2e2c75b20f59379c8 Mon Sep 17 00:00:00 2001 From: Stephen Heumann Date: Sun, 9 Sep 2018 23:23:19 -0500 Subject: [PATCH] Add _Exit() function from C99. This exits the programs without calling atexit functions and possibly without doing other clean-up operations. In ORCA/C, it is functionally identical to _exit(). --- stdlib.asm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/stdlib.asm b/stdlib.asm index 7dfafbb..0ee837c 100644 --- a/stdlib.asm +++ b/stdlib.asm @@ -301,6 +301,9 @@ div_t ds 4 * void _exit(status) * int status; * +* void _Exit(status) +* int status; +* * Stop the program. Exit cleans up, _exit does not. Status * is the status returned to the shell. * @@ -313,6 +316,7 @@ exit start jsr ~EXIT _exit entry +_Exit entry lda 4,S jmp ~QUIT end