[libcxx-commits] [PATCH] D72456: [libcxx] [test] Portability fix for some locale-dependent tests.

Andrey Maksimov via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu Jan 9 07:43:34 PST 2020


amakc11 created this revision.
Herald added a reviewer: EricWF.
Herald added subscribers: libcxx-commits, ldionne, christof.
Herald added a project: libc++.

Tests for `std::system_error` constructor marked as "slightly non-portable". One (but not the only one) reason for such non-portability is that these tests assume the default locale to be set to "C" (or "POSIX"). However, the default locale for the process depends on OS and environment. This patch adds explicit setting of the correct locale expected by the tests.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D72456

Files:
  libcxx/test/std/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_error_code.pass.cpp
  libcxx/test/std/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_error_code_const_char_pointer.pass.cpp
  libcxx/test/std/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_error_code_string.pass.cpp
  libcxx/test/std/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_int_error_category.pass.cpp
  libcxx/test/std/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_int_error_category_const_char_pointer.pass.cpp
  libcxx/test/std/diagnostics/syserr/syserr.syserr/syserr.syserr.members/ctor_int_error_category_string.pass.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D72456.237073.patch
Type: text/x-patch
Size: 4809 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20200109/95ff9d24/attachment.bin>


More information about the libcxx-commits mailing list