From 1d808be4b9524ed3ce6e9b3518814d5c62a87bde Mon Sep 17 00:00:00 2001 From: Christoffer Lerno Date: Tue, 26 Jul 2022 15:07:37 +0200 Subject: [PATCH] Fix stdout defaults. --- lib/std/libc.c3 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/std/libc.c3 b/lib/std/libc.c3 index 344a9aa58..ee314d55e 100644 --- a/lib/std/libc.c3 +++ b/lib/std/libc.c3 @@ -116,6 +116,9 @@ $case OsType.WIN32: macro CFile stdout() { return __acrt_iob_func(1); } macro CFile stderr() { return __acrt_iob_func(2); } $default: + macro CFile stdin() { return (CFile*)(uptr)0; } + macro CFile stdout() { return (CFile*)(uptr)1; } + macro CFile stderr() { return (CFile*)(uptr)2; } $endswitch; // The following needs to be set per arch+os