diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2016-02-10 00:59:02 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2016-02-10 00:59:02 +0000 |
commit | 5fd17ab1b093f6b59aabb27f6c2c2278e65c2707 (patch) | |
tree | cb54a6dfa5d6d92ab253e36c131c5dceb30a29de /libcxx/test/std/depr/depr.c.headers/uchar_h.pass.cpp | |
parent | 755a4e6b5736fca0d41c13856a7a34780c0cbd64 (diff) | |
download | bcm5719-llvm-5fd17ab1b093f6b59aabb27f6c2c2278e65c2707.tar.gz bcm5719-llvm-5fd17ab1b093f6b59aabb27f6c2c2278e65c2707.zip |
Fix overload sets of strchr, strpbrk, strrchr, memchr and strstr from
<string.h> and wcschr, wcspbrk, wcsrchr, wmemchr, and wcsstr from <wchar.h> to
provide a const-correct overload set even when the underlying C library does
not.
This change adds a new macro, _LIBCPP_PREFERRED_OVERLOAD, which (if defined)
specifies that a given overload is a better match than an otherwise equally
good function declaration without the overload. This is implemented in modern
versions of Clang via __attribute__((enable_if)), and not elsewhere.
We use this new macro to define overloads in the global namespace for these
functions that displace the overloads provided by the C library, unless we
believe the C library is already providing the correct signatures.
llvm-svn: 260337
Diffstat (limited to 'libcxx/test/std/depr/depr.c.headers/uchar_h.pass.cpp')
0 files changed, 0 insertions, 0 deletions