diff options
author | Louis Dionne <ldionne@apple.com> | 2019-04-26 16:46:37 +0000 |
---|---|---|
committer | Louis Dionne <ldionne@apple.com> | 2019-04-26 16:46:37 +0000 |
commit | f30f261dc531b289bc74c157178e5bbc4a6ff7c9 (patch) | |
tree | fdceaf33390958901a7ba71c4fe6e1a59dc7d9b8 | |
parent | edebf12acfe2f83822510a780377f3b36177d478 (diff) | |
download | bcm5719-llvm-f30f261dc531b289bc74c157178e5bbc4a6ff7c9.tar.gz bcm5719-llvm-f30f261dc531b289bc74c157178e5bbc4a6ff7c9.zip |
[libc++] Relax libc++-only test on regex_constants
The standard requires the following for the std::regex_constants::error_type
values: "The type error_type is an implementation-defined enumerated type."
The values of this enumerated type are not required to be non-zero.
This patch makes such checks in tests libc++-specific to let the tests
pass for other conforming implementations.
Thanks to Andrey Maksimov for the patch.
Differential Revision: https://reviews.llvm.org/D61195
llvm-svn: 359320
-rw-r--r-- | libcxx/test/std/re/re.const/re.err/error_type.pass.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/libcxx/test/std/re/re.const/re.err/error_type.pass.cpp b/libcxx/test/std/re/re.const/re.err/error_type.pass.cpp index 51979a5113f..dbecf4798b4 100644 --- a/libcxx/test/std/re/re.const/re.err/error_type.pass.cpp +++ b/libcxx/test/std/re/re.const/re.err/error_type.pass.cpp @@ -37,19 +37,19 @@ int main(int, char**) { - assert(std::regex_constants::error_collate != 0); - assert(std::regex_constants::error_ctype != 0); - assert(std::regex_constants::error_escape != 0); - assert(std::regex_constants::error_backref != 0); - assert(std::regex_constants::error_brack != 0); - assert(std::regex_constants::error_paren != 0); - assert(std::regex_constants::error_brace != 0); - assert(std::regex_constants::error_badbrace != 0); - assert(std::regex_constants::error_range != 0); - assert(std::regex_constants::error_space != 0); - assert(std::regex_constants::error_badrepeat != 0); - assert(std::regex_constants::error_complexity != 0); - assert(std::regex_constants::error_stack != 0); + LIBCPP_ASSERT(std::regex_constants::error_collate != 0); + LIBCPP_ASSERT(std::regex_constants::error_ctype != 0); + LIBCPP_ASSERT(std::regex_constants::error_escape != 0); + LIBCPP_ASSERT(std::regex_constants::error_backref != 0); + LIBCPP_ASSERT(std::regex_constants::error_brack != 0); + LIBCPP_ASSERT(std::regex_constants::error_paren != 0); + LIBCPP_ASSERT(std::regex_constants::error_brace != 0); + LIBCPP_ASSERT(std::regex_constants::error_badbrace != 0); + LIBCPP_ASSERT(std::regex_constants::error_range != 0); + LIBCPP_ASSERT(std::regex_constants::error_space != 0); + LIBCPP_ASSERT(std::regex_constants::error_badrepeat != 0); + LIBCPP_ASSERT(std::regex_constants::error_complexity != 0); + LIBCPP_ASSERT(std::regex_constants::error_stack != 0); assert(std::regex_constants::error_collate != std::regex_constants::error_ctype); assert(std::regex_constants::error_collate != std::regex_constants::error_escape); |