[libcxx] [test] Use TEST_IGNORE_NODISCARD.

Fixes D45595.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@329979 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Stephan T. Lavavej
2018-04-13 00:07:48 +00:00
parent c538ab0daa
commit a9d48f24c5

View File

@@ -33,7 +33,7 @@ int main()
Myconv myconv; Myconv myconv;
try try
{ {
(void)myconv.to_bytes(L"\xDA83"); TEST_IGNORE_NODISCARD myconv.to_bytes(L"\xDA83");
assert(false); assert(false);
} }
catch (const std::range_error&) catch (const std::range_error&)
@@ -41,7 +41,7 @@ int main()
} }
try try
{ {
(void)myconv.from_bytes('\xA5'); TEST_IGNORE_NODISCARD myconv.from_bytes('\xA5');
assert(false); assert(false);
} }
catch (const std::range_error&) catch (const std::range_error&)
@@ -56,7 +56,7 @@ int main()
#ifndef TEST_HAS_NO_EXCEPTIONS #ifndef TEST_HAS_NO_EXCEPTIONS
try try
{ {
(void)myconv.from_bytes('\xA5'); TEST_IGNORE_NODISCARD myconv.from_bytes('\xA5');
assert(false); assert(false);
} }
catch (const std::range_error&) catch (const std::range_error&)