summaryrefslogtreecommitdiffhomepage
path: root/dev/LibC++/process_base.h
diff options
context:
space:
mode:
authorAmlal <amlal.elmahrouss@icloud.com>2024-11-01 19:41:55 +0100
committerAmlal <amlal.elmahrouss@icloud.com>2024-11-01 19:41:55 +0100
commit9832d04842245987a1af284866628c5f9bb1fa1b (patch)
tree68ce21ad31b164c15d841e85451540292b624348 /dev/LibC++/process_base.h
parent65fb4a1abc5ad8b0dd4f2f31199f53a748167f24 (diff)
IMP: Fixes and improvements to LibC++, add shell script to generate standard C+ headers.
Signed-off-by: Amlal <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'dev/LibC++/process_base.h')
-rw-r--r--dev/LibC++/process_base.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/dev/LibC++/process_base.h b/dev/LibC++/process_base.h
new file mode 100644
index 0000000..9d7c95c
--- /dev/null
+++ b/dev/LibC++/process_base.h
@@ -0,0 +1,21 @@
+/* -------------------------------------------
+
+ Copyright EL Mahrouss Logic.
+
+------------------------------------------- */
+
+#pragma once
+
+/// @brief CRT exit, with exit code (!!! exits all threads. !!!)
+/// @param code the exit code.
+/// @return the return > 0 for non successful.
+extern "C" int exit(int code);
+
+/// @brief Standard C++ namespace
+namespace std::process_base
+{
+ inline int exit(int code)
+ {
+ exit(code);
+ }
+} // namespace std::process_base