From f900849f98bad9988805ec89c587395752490486 Mon Sep 17 00:00:00 2001 From: Amlal El Mahrouss Date: Sat, 29 Nov 2025 22:21:44 -0500 Subject: chore: API and system design update. Signed-off-by: Amlal El Mahrouss --- src/LibC++/base_process.h | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) (limited to 'src/LibC++/base_process.h') diff --git a/src/LibC++/base_process.h b/src/LibC++/base_process.h index f9b0596..cb25aa1 100644 --- a/src/LibC++/base_process.h +++ b/src/LibC++/base_process.h @@ -10,10 +10,10 @@ __init_decl() -/// @brief CRT exit, with exit code (!!! exits all threads. !!!) -/// @param code the exit code. -/// @return the return > 0 for non successful. -extern int exit_(int code); + /// @brief CRT exit, with exit code (!!! exits all threads. !!!) + /// @param code the exit code. + /// @return the return > 0 for non successful. + extern int exit_(int code); /// @brief CRT signal handler. /// @param code the signal code. @@ -25,21 +25,21 @@ extern size_t __atexit_lst_cnt; __fini_decl() -/// @brief Standard C++ namespace -namespace std::base_process { -inline int signal(int code) { - signal_(code); - return -1; -} - -inline int32_t exit(const int32_t& code) { - for (auto idx = 0UL; idx < __atexit_lst_cnt; ++idx) { - __atexit_lst_ptr[idx](); + /// @brief Standard C++ namespace + namespace std::base_process { + inline int signal(int code) { + signal_(code); + return -1; } - if (__atexit_cdecl_ptr) __atexit_cdecl_ptr(); + inline int32_t exit(const int32_t& code) { + for (auto idx = 0UL; idx < __atexit_lst_cnt; ++idx) { + __atexit_lst_ptr[idx](); + } + + if (__atexit_cdecl_ptr) __atexit_cdecl_ptr(); - exit_(code); - return -1; -} + exit_(code); + return -1; + } } // namespace std::base_process -- cgit v1.2.3