[libc-commits] [libc] Add _exit() according to _Exit() implementation (PR #87184)
via libc-commits
libc-commits at lists.llvm.org
Sun Mar 31 00:14:51 PDT 2024
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-libc
Author: Max (maebex)
<details>
<summary>Changes</summary>
Fixes llvm/llvm-project#<!-- -->86671
---
Full diff: https://github.com/llvm/llvm-project/pull/87184.diff
2 Files Affected:
- (modified) libc/src/stdlib/_Exit.cpp (+4)
- (modified) libc/src/stdlib/_Exit.h (+2)
``````````diff
diff --git a/libc/src/stdlib/_Exit.cpp b/libc/src/stdlib/_Exit.cpp
index 233af209739244..f7ac84a1a77dd1 100644
--- a/libc/src/stdlib/_Exit.cpp
+++ b/libc/src/stdlib/_Exit.cpp
@@ -17,4 +17,8 @@ namespace LIBC_NAMESPACE {
quick_exit(status);
}
+[[noreturn]] LLVM_LIBC_FUNCTION(void, _exit, (int status)) {
+ quick_exit(status);
+}
+
} // namespace LIBC_NAMESPACE
diff --git a/libc/src/stdlib/_Exit.h b/libc/src/stdlib/_Exit.h
index bc05fafeb766b2..c0aea82ccdc5d8 100644
--- a/libc/src/stdlib/_Exit.h
+++ b/libc/src/stdlib/_Exit.h
@@ -13,6 +13,8 @@ namespace LIBC_NAMESPACE {
[[noreturn]] void _Exit(int status);
+[[noreturn]] void _exit(int status);
+
} // namespace LIBC_NAMESPACE
#endif // LLVM_LIBC_SRC_STDLIB__EXIT_H
``````````
</details>
https://github.com/llvm/llvm-project/pull/87184
More information about the libc-commits
mailing list