Void cast runtime-unused variables. Patch from STL@microsoft.com

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@268284 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Fiselier
2016-05-02 19:15:48 +00:00
parent 61a220ae5b
commit a9ea11398d
23 changed files with 69 additions and 15 deletions

View File

@@ -47,6 +47,7 @@
int main()
{
std::lconv lc;
((void)lc); // Prevent unused warning
#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
static_assert((std::is_same<decltype(std::setlocale(0, "")), char*>::value), "");
#endif

View File

@@ -24415,7 +24415,6 @@ void test11()
void test12()
{
char str[200];
output_iterator<char*> iter;
std::locale lc = std::locale::classic();
std::locale lg(lc, new my_numpunct);
@@ -24423,6 +24422,7 @@ void test12()
// This test is failing on FreeBSD, possibly due to different representations
// of the floating point numbers.
const my_facet f(1);
char str[200];
{
long double v = 1234567890.125;
std::ios ios(0);
@@ -26221,7 +26221,6 @@ int main()
test10();
test11();
test12();
char str[200];
output_iterator<char*> iter;
std::locale lc = std::locale::classic();
std::locale lg(lc, new my_numpunct);