diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2022-07-27 19:50:45 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2022-07-27 19:50:54 +0000 |
| commit | 08e8dd7b9db7bb4a9de26d44c1cbfd24e869c014 (patch) | |
| tree | 041e72e32710b1e742516d8c9f1575bf0116d3e3 /libcxx/include/__assert | |
| parent | 4b4fe385e49bd883fd183b5f21c1ea486c722e61 (diff) | |
Vendor import of llvm-project main llvmorg-15-init-17826-g1f8ae9d7e7e4,vendor/llvm-project/llvmorg-15-init-17827-gd77882e66779vendor/llvm-project/llvmorg-15-init-17826-g1f8ae9d7e7e4
the last commit before the upstream release/16.x branch was created.
Diffstat (limited to 'libcxx/include/__assert')
| -rw-r--r-- | libcxx/include/__assert | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libcxx/include/__assert b/libcxx/include/__assert index 84ddcd25b0b5..82db2cf052b5 100644 --- a/libcxx/include/__assert +++ b/libcxx/include/__assert @@ -45,7 +45,7 @@ # define _LIBCPP_ASSERT(expression, message) \ (__builtin_expect(static_cast<bool>(expression), 1) ? \ (void)0 : \ - ::std::__libcpp_assertion_handler(__FILE__, __LINE__, #expression, message)) + ::std::__libcpp_assertion_handler("%s:%d: assertion %s failed: %s", __FILE__, __LINE__, #expression, message)) #elif !defined(_LIBCPP_ASSERTIONS_DISABLE_ASSUME) && __has_builtin(__builtin_assume) # define _LIBCPP_ASSERT(expression, message) \ (_LIBCPP_DIAGNOSTIC_PUSH \ @@ -58,8 +58,8 @@ _LIBCPP_BEGIN_NAMESPACE_STD -_LIBCPP_OVERRIDABLE_FUNC_VIS _LIBCPP_AVAILABILITY_ASSERTION_HANDLER -void __libcpp_assertion_handler(char const* __file, int __line, char const* __expression, char const* __message); +_LIBCPP_OVERRIDABLE_FUNC_VIS _LIBCPP_AVAILABILITY_ASSERTION_HANDLER _LIBCPP_ATTRIBUTE_FORMAT(__printf__, 1, 2) +void __libcpp_assertion_handler(const char *__format, ...); _LIBCPP_END_NAMESPACE_STD |
