diff options
author | Eric Fiselier <eric@efcs.ca> | 2016-05-02 20:08:16 +0000 |
---|---|---|
committer | Eric Fiselier <eric@efcs.ca> | 2016-05-02 20:08:16 +0000 |
commit | 76af416afc02c53ce636057661d88e54dbfd2465 (patch) | |
tree | 89e50d5ec8d89c62c55b69563e300762dcaa41bd /libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp | |
parent | 2b957b5a6f228797a871426d48098fee479883ef (diff) | |
download | bcm5719-llvm-76af416afc02c53ce636057661d88e54dbfd2465.tar.gz bcm5719-llvm-76af416afc02c53ce636057661d88e54dbfd2465.zip |
Cleanup warnings and remove use of __builtin_va_list in depr.c.headers
llvm-svn: 268294
Diffstat (limited to 'libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp')
-rw-r--r-- | libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp | 21 |
1 files changed, 5 insertions, 16 deletions
diff --git a/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp b/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp index 6bd2b2d3098..d7d9bfc85b5 100644 --- a/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp +++ b/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp @@ -10,6 +10,7 @@ // <wchar.h> #include <wchar.h> +#include <stdarg.h> #include <type_traits> #ifndef NULL @@ -31,27 +32,15 @@ int main() { // mbstate_t comes from the underlying C library; it is defined (in C99) as: -// a complete object type other than an array type that can hold the conversion -// state information necessary to convert between sequences of multibyte +// a complete object type other than an array type that can hold the conversion +// state information necessary to convert between sequences of multibyte // characters and wide characters -#if defined(__clang__) -#pragma clang diagnostic push -#pragma clang diagnostic ignored "-Wmissing-braces" -#endif - mbstate_t mb = {0}; -#if defined(__clang__) -#pragma clang diagnostic pop -#endif - + mbstate_t mb = {}; size_t s = 0; tm *tm = 0; wint_t w = 0; ::FILE* fp = 0; -#ifdef __APPLE__ - __darwin_va_list va; -#else - __builtin_va_list va; -#endif + ::va_list va; char* ns = 0; wchar_t* ws = 0; static_assert((std::is_same<decltype(fwprintf(fp, L"")), int>::value), ""); |