diff options
| author | Eric Fiselier <eric@efcs.ca> | 2017-02-04 23:22:28 +0000 |
|---|---|---|
| committer | Eric Fiselier <eric@efcs.ca> | 2017-02-04 23:22:28 +0000 |
| commit | e49cdfbeea99ba94ed3d8a46b9943b272dbd9c5f (patch) | |
| tree | 7dc16aa7afd24344bb01d80de74782ba169461a1 /libcxx/include | |
| parent | 5ddaeb888d807b5512546d5f666a581afddde6cc (diff) | |
| download | bcm5719-llvm-e49cdfbeea99ba94ed3d8a46b9943b272dbd9c5f.tar.gz bcm5719-llvm-e49cdfbeea99ba94ed3d8a46b9943b272dbd9c5f.zip | |
Recommit [libcxx] Never use <cassert> within libc++
It is my opinion that libc++ should never use `<cassert>`, including in the `dylib`.
This patch remove all uses of `assert` from within libc++ and replaces most of them with `_LIBCPP_ASSERT` instead.
Additionally this patch turn `LIBCXX_ENABLE_ASSERTIONS` off by default,
because the standard library should not be aborting user programs unless explicitly asked to.
llvm-svn: 294107
Diffstat (limited to 'libcxx/include')
| -rw-r--r-- | libcxx/include/__config | 2 | ||||
| -rw-r--r-- | libcxx/include/__threading_support | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/libcxx/include/__config b/libcxx/include/__config index 1fedc04d30a..a70f8f0060f 100644 --- a/libcxx/include/__config +++ b/libcxx/include/__config @@ -817,7 +817,9 @@ template <unsigned> struct __static_assert_check {}; # else # error Supported values for _LIBCPP_DEBUG are 0 and 1 # endif +# if !defined(_LIBCPP_BUILDING_LIBRARY) # define _LIBCPP_EXTERN_TEMPLATE(...) +# endif #endif #ifndef _LIBCPP_EXTERN_TEMPLATE diff --git a/libcxx/include/__threading_support b/libcxx/include/__threading_support index d049c9193d9..53a956ed980 100644 --- a/libcxx/include/__threading_support +++ b/libcxx/include/__threading_support @@ -25,7 +25,6 @@ # include <pthread.h> # include <sched.h> #elif defined(_LIBCPP_HAS_THREAD_API_WIN32) -#include <assert.h> #include <Windows.h> #include <process.h> #include <fibersapi.h> |

