From b7b47fe13004bf70d6ec72f080c40887d76700b3 Mon Sep 17 00:00:00 2001 From: syrmel <104119569+syrmel@users.noreply.github.com> Date: Thu, 8 Feb 2024 12:20:50 +0100 Subject: [PATCH] os: make os.SystemError struct public so the os.error_* functions can be used by other modules (#20754) --- vlib/os/os.c.v | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/vlib/os/os.c.v b/vlib/os/os.c.v index 86cdcfb2c3..49ba4d3b18 100644 --- a/vlib/os/os.c.v +++ b/vlib/os/os.c.v @@ -1158,10 +1158,11 @@ pub fn last_error() IError { } // Magic constant because zero is used explicitly at times -const error_code_not_set = 0x7EFEFEFE +pub const error_code_not_set = 0x7EFEFEFE @[params] -struct SystemError { +pub struct SystemError { +pub: msg string code int = os.error_code_not_set }