diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:47:26 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:47:26 +0000 |
| commit | 51072bd6bf79ef2bc6a922079bff57c31c1effbc (patch) | |
| tree | 91a2effbc9e6f80bdbbf9eb70e06c51ad0867ea0 /test/std/input.output/file.streams/c.files/cstdio.pass.cpp | |
| parent | bb5e33f003797b67974a8893f7f2930fc51b8210 (diff) | |
Notes
Diffstat (limited to 'test/std/input.output/file.streams/c.files/cstdio.pass.cpp')
| -rw-r--r-- | test/std/input.output/file.streams/c.files/cstdio.pass.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/test/std/input.output/file.streams/c.files/cstdio.pass.cpp b/test/std/input.output/file.streams/c.files/cstdio.pass.cpp index a06f0443d701..4c2be7d4aa9e 100644 --- a/test/std/input.output/file.streams/c.files/cstdio.pass.cpp +++ b/test/std/input.output/file.streams/c.files/cstdio.pass.cpp @@ -78,17 +78,24 @@ #include <cstdarg> +#if defined(__clang__) #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wformat-zero-length" #pragma clang diagnostic ignored "-Wdeprecated-declarations" +#endif int main() { std::FILE* fp = 0; - std::fpos_t fpos = {0}; + std::fpos_t fpos = {}; std::size_t s = 0; char* cp = 0; std::va_list va; + ((void)fp); // Prevent unused warning + ((void)fpos); // Prevent unused warning + ((void)s); // Prevent unused warning + ((void)cp); // Prevent unused warning + ((void)va); // Prevent unused warning static_assert((std::is_same<decltype(std::fclose(fp)), int>::value), ""); static_assert((std::is_same<decltype(std::fflush(fp)), int>::value), ""); static_assert((std::is_same<decltype(std::setbuf(fp,cp)), void>::value), ""); |
