From 3eb7dfb28552a740ee81ac34d98cbf5429766166 Mon Sep 17 00:00:00 2001 From: bkoz Date: Tue, 15 Apr 2003 06:36:31 +0000 Subject: [PATCH] 2003-04-14 Andreas Tobler Benjamin Kosnik * config/os/generic/ctype_inline.h: Fix. 2003-04-14 Benjamin Kosnik * testsuite/testsuite_hooks.h (__gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher): Change to run_named_locale_test. * testsuite/testsuite_hooks.cc (__gnu_cxx_test): Same. * testsuite/22_locale/codecvt/always_noconv/wchar_t/2.cc: Use run_test_named_locale. * testsuite/22_locale/codecvt/always_noconv/wchar_t/3.cc: Same. * testsuite/22_locale/codecvt/always_noconv/wchar_t/4.cc: Same. * testsuite/22_locale/codecvt/encoding/wchar_t/2.cc: Same. * testsuite/22_locale/codecvt/encoding/wchar_t/3.cc: Same. * testsuite/22_locale/codecvt/encoding/wchar_t/4.cc: Same. * testsuite/22_locale/codecvt/in/wchar_t/2.cc: Same. * testsuite/22_locale/codecvt/in/wchar_t/3.cc: Same. * testsuite/22_locale/codecvt/in/wchar_t/4.cc: Same. * testsuite/22_locale/codecvt/in/wchar_t/7.cc: Same. * testsuite/22_locale/codecvt/in/wchar_t/8.cc: Same. * testsuite/22_locale/codecvt/in/wchar_t/9.cc: Same. * testsuite/22_locale/codecvt/length/wchar_t/2.cc: Same. * testsuite/22_locale/codecvt/length/wchar_t/3.cc: Same. * testsuite/22_locale/codecvt/length/wchar_t/4.cc: Same. * testsuite/22_locale/codecvt/length/wchar_t/7.cc: Same. * testsuite/22_locale/codecvt/max_length/wchar_t/2.cc: Same. * testsuite/22_locale/codecvt/max_length/wchar_t/3.cc: Same. * testsuite/22_locale/codecvt/max_length/wchar_t/4.cc: Same. * testsuite/22_locale/codecvt/out/wchar_t/2.cc: Same. * testsuite/22_locale/codecvt/out/wchar_t/3.cc: Same. * testsuite/22_locale/codecvt/out/wchar_t/4.cc: Same. * testsuite/22_locale/codecvt/out/wchar_t/7.cc: Same. * testsuite/22_locale/codecvt/unshift/wchar_t/2.cc: Same. * testsuite/22_locale/codecvt/unshift/wchar_t/3.cc: Same. * testsuite/22_locale/codecvt/unshift/wchar_t/4.cc: Same. * testsuite/22_locale/collate/compare/char/1.cc: Same. * testsuite/22_locale/collate/compare/char/2.cc: Same. * testsuite/22_locale/collate/compare/char/3.cc: Same. * testsuite/22_locale/collate/compare/wchar_t/1.cc: Same. * testsuite/22_locale/collate/compare/wchar_t/2.cc: Same. * testsuite/22_locale/collate/compare/wchar_t/3.cc: Same. * testsuite/22_locale/collate/hash/char/2.cc: Same. * testsuite/22_locale/collate/hash/wchar_t/2.cc: Same. * testsuite/22_locale/collate/transform/char/2.cc: Same. * testsuite/22_locale/collate/transform/char/3.cc: Same. * testsuite/22_locale/collate/transform/wchar_t/2.cc: Same. * testsuite/22_locale/collate/transform/wchar_t/3.cc: Same. * testsuite/22_locale/collate_byname/1.cc: Same. * testsuite/22_locale/ctype/is/char/2.cc: Same. * testsuite/22_locale/ctype/is/wchar_t/2.cc: Same. * testsuite/22_locale/ctype/narrow/wchar_t/3.cc: Same. * testsuite/22_locale/ctype/widen/wchar_t/2.cc: Same. * testsuite/22_locale/ctype/widen/wchar_t/3.cc: Same. * testsuite/22_locale/facet/2.cc: Same. * testsuite/22_locale/locale/cons/2.cc: Same. * testsuite/22_locale/locale/cons/4.cc: Same. * testsuite/22_locale/locale/cons/5.cc: Same. * testsuite/22_locale/locale/cons/7.cc: Same. * testsuite/22_locale/locale/cons/7222-c.cc: Same. * testsuite/22_locale/locale/cons/7222-env.cc: Same. * testsuite/22_locale/locale/global_locale_objects/2.cc: Same. * testsuite/22_locale/messages/members/char/1.cc: Same. * testsuite/22_locale/messages/members/char/2.cc: Same. * testsuite/22_locale/messages/members/char/3.cc: Same. * testsuite/22_locale/messages_byname/1.cc: Same. * testsuite/22_locale/money_get/get/char/1.cc: Same. * testsuite/22_locale/money_get/get/char/2.cc: Same. * testsuite/22_locale/money_get/get/char/3.cc: Same. * testsuite/22_locale/money_get/get/char/4.cc: Same. * testsuite/22_locale/money_get/get/wchar_t/1.cc: Same. * testsuite/22_locale/money_get/get/wchar_t/2.cc: Same. * testsuite/22_locale/money_get/get/wchar_t/3.cc: Same. * testsuite/22_locale/money_get/get/wchar_t/4.cc: Same. * testsuite/22_locale/money_put/put/char/1.cc: Same. * testsuite/22_locale/money_put/put/char/2.cc: Same. * testsuite/22_locale/money_put/put/char/3.cc: Same. * testsuite/22_locale/money_put/put/wchar_t/1.cc: Same. * testsuite/22_locale/money_put/put/wchar_t/2.cc: Same. * testsuite/22_locale/money_put/put/wchar_t/3.cc: Same. * testsuite/22_locale/moneypunct/members/char/2.cc: Same. * testsuite/22_locale/moneypunct/members/wchar_t/2.cc: Same. * testsuite/22_locale/moneypunct_byname/1.cc: Same. * testsuite/22_locale/num_get/get/char/1.cc: Same. * testsuite/22_locale/num_get/get/char/2.cc: Same. * testsuite/22_locale/num_get/get/char/3.cc: Same. * testsuite/22_locale/num_get/get/char/5.cc: Same. * testsuite/22_locale/num_get/get/char/6.cc: Same. * testsuite/22_locale/num_get/get/wchar_t/1.cc: Same. * testsuite/22_locale/num_get/get/wchar_t/2.cc: Same. * testsuite/22_locale/num_get/get/wchar_t/3.cc: Same. * testsuite/22_locale/num_get/get/wchar_t/5.cc: Same. * testsuite/22_locale/num_get/get/wchar_t/6.cc: Same. * testsuite/22_locale/num_put/put/char/1.cc: Same. * testsuite/22_locale/num_put/put/char/2.cc: Same. * testsuite/22_locale/num_put/put/char/3.cc: Same. * testsuite/22_locale/num_put/put/char/5.cc: Same. * testsuite/22_locale/num_put/put/wchar_t/1.cc: Same. * testsuite/22_locale/num_put/put/wchar_t/2.cc: Same. * testsuite/22_locale/num_put/put/wchar_t/3.cc: Same. * testsuite/22_locale/num_put/put/wchar_t/5.cc: Same. * testsuite/22_locale/numpunct/members/char/1.cc: Same. * testsuite/22_locale/numpunct/members/char/2.cc: Same. * testsuite/22_locale/numpunct/members/wchar_t/1.cc: Same. * testsuite/22_locale/numpunct/members/wchar_t/2.cc: Same. * testsuite/22_locale/numpunct_byname/1.cc: Same. * testsuite/22_locale/numpunct_byname/2.cc: Same. * testsuite/22_locale/time_get/date_order/char/1.cc: Same. * testsuite/22_locale/time_get/date_order/wchar_t/1.cc: Same. * testsuite/22_locale/time_get/get_date/char/1.cc: Same. * testsuite/22_locale/time_get/get_date/char/2.cc: Same. * testsuite/22_locale/time_get/get_date/wchar_t/1.cc: Same. * testsuite/22_locale/time_get/get_date/wchar_t/2.cc: Same. * testsuite/22_locale/time_get/get_monthname/char/1.cc: Same. * testsuite/22_locale/time_get/get_monthname/char/2.cc: Same. * testsuite/22_locale/time_get/get_monthname/wchar_t/1.cc: Same. * testsuite/22_locale/time_get/get_monthname/wchar_t/2.cc: Same. * testsuite/22_locale/time_get/get_time/char/1.cc: Same. * testsuite/22_locale/time_get/get_time/char/2.cc: Same. * testsuite/22_locale/time_get/get_time/wchar_t/1.cc: Same. * testsuite/22_locale/time_get/get_time/wchar_t/2.cc: Same. * testsuite/22_locale/time_get/get_weekday/char/1.cc: Same. * testsuite/22_locale/time_get/get_weekday/char/2.cc: Same. * testsuite/22_locale/time_get/get_weekday/wchar_t/1.cc: Same. * testsuite/22_locale/time_get/get_weekday/wchar_t/2.cc: Same. * testsuite/22_locale/time_get/get_year/char/1.cc: Same. * testsuite/22_locale/time_get/get_year/wchar_t/1.cc: Same. * testsuite/22_locale/time_put/put/char/1.cc: Same. * testsuite/22_locale/time_put/put/char/2.cc: Same. * testsuite/22_locale/time_put/put/char/3.cc: Same. * testsuite/22_locale/time_put/put/char/4.cc: Same. * testsuite/22_locale/time_put/put/char/5.cc: Same. * testsuite/22_locale/time_put/put/char/6.cc: Same. * testsuite/22_locale/time_put/put/char/7.cc: Same. * testsuite/22_locale/time_put/put/char/8.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/1.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/2.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/3.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/4.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/5.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/6.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/7.cc: Same. * testsuite/22_locale/time_put/put/wchar_t/8.cc: Same. * testsuite/27_io/basic_filebuf/imbue/char/9322.cc: Same. * testsuite/27_io/basic_ios/copyfmt/char/2.cc: Same. * testsuite/27_io/basic_ostream/inserters_arithmetic/char/2.cc: Same. * testsuite/27_io/basic_streambuf/imbue/char/9322.cc: Same. * testsuite/27_io/basic_stringbuf/imbue/char/9322.cc: Same. 2003-04-14 Andreas Tobler * configure.target (_cpu_incdir_fullpath): Solaris 2.9 uses solaris includes, not generic. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@65622 138bc75d-0d04-0410-961f-82ee72b054a4 --- libstdc++-v3/ChangeLog | 157 +++++++++++++++++++++ libstdc++-v3/config/locale/generic/c_locale.cc | 4 +- libstdc++-v3/config/os/generic/ctype_inline.h | 142 ++++++++++++------- libstdc++-v3/configure.target | 2 +- .../22_locale/codecvt/always_noconv/wchar_t/2.cc | 2 +- .../22_locale/codecvt/always_noconv/wchar_t/3.cc | 2 +- .../22_locale/codecvt/always_noconv/wchar_t/4.cc | 2 +- .../22_locale/codecvt/encoding/wchar_t/2.cc | 2 +- .../22_locale/codecvt/encoding/wchar_t/3.cc | 2 +- .../22_locale/codecvt/encoding/wchar_t/4.cc | 2 +- .../testsuite/22_locale/codecvt/in/wchar_t/2.cc | 2 +- .../testsuite/22_locale/codecvt/in/wchar_t/3.cc | 2 +- .../testsuite/22_locale/codecvt/in/wchar_t/4.cc | 2 +- .../testsuite/22_locale/codecvt/in/wchar_t/7.cc | 2 +- .../testsuite/22_locale/codecvt/in/wchar_t/8.cc | 2 +- .../testsuite/22_locale/codecvt/in/wchar_t/9.cc | 2 +- .../22_locale/codecvt/length/wchar_t/2.cc | 2 +- .../22_locale/codecvt/length/wchar_t/3.cc | 2 +- .../22_locale/codecvt/length/wchar_t/4.cc | 2 +- .../22_locale/codecvt/length/wchar_t/7.cc | 2 +- .../22_locale/codecvt/max_length/wchar_t/2.cc | 2 +- .../22_locale/codecvt/max_length/wchar_t/3.cc | 2 +- .../22_locale/codecvt/max_length/wchar_t/4.cc | 2 +- .../testsuite/22_locale/codecvt/out/wchar_t/2.cc | 2 +- .../testsuite/22_locale/codecvt/out/wchar_t/3.cc | 2 +- .../testsuite/22_locale/codecvt/out/wchar_t/4.cc | 2 +- .../testsuite/22_locale/codecvt/out/wchar_t/7.cc | 2 +- .../22_locale/codecvt/unshift/wchar_t/2.cc | 2 +- .../22_locale/codecvt/unshift/wchar_t/3.cc | 2 +- .../22_locale/codecvt/unshift/wchar_t/4.cc | 2 +- .../testsuite/22_locale/collate/compare/char/1.cc | 8 +- .../testsuite/22_locale/collate/compare/char/2.cc | 8 +- .../testsuite/22_locale/collate/compare/char/3.cc | 4 +- .../22_locale/collate/compare/wchar_t/1.cc | 6 +- .../22_locale/collate/compare/wchar_t/2.cc | 6 +- .../22_locale/collate/compare/wchar_t/3.cc | 2 +- .../testsuite/22_locale/collate/hash/char/2.cc | 8 +- .../testsuite/22_locale/collate/hash/wchar_t/2.cc | 6 +- .../22_locale/collate/transform/char/2.cc | 8 +- .../22_locale/collate/transform/char/3.cc | 4 +- .../22_locale/collate/transform/wchar_t/2.cc | 6 +- .../22_locale/collate/transform/wchar_t/3.cc | 2 +- .../testsuite/22_locale/collate_byname/1.cc | 8 +- .../testsuite/22_locale/ctype/is/char/2.cc | 4 +- .../testsuite/22_locale/ctype/is/wchar_t/2.cc | 2 +- .../testsuite/22_locale/ctype/narrow/wchar_t/3.cc | 2 +- .../testsuite/22_locale/ctype/widen/wchar_t/2.cc | 2 +- .../testsuite/22_locale/ctype/widen/wchar_t/3.cc | 2 +- libstdc++-v3/testsuite/22_locale/facet/2.cc | 4 +- libstdc++-v3/testsuite/22_locale/locale/cons/2.cc | 4 +- libstdc++-v3/testsuite/22_locale/locale/cons/4.cc | 4 +- libstdc++-v3/testsuite/22_locale/locale/cons/5.cc | 16 +-- libstdc++-v3/testsuite/22_locale/locale/cons/7.cc | 4 +- .../testsuite/22_locale/locale/cons/7222-c.cc | 2 +- .../testsuite/22_locale/locale/cons/7222-env.cc | 6 +- .../22_locale/locale/global_locale_objects/2.cc | 8 +- .../testsuite/22_locale/messages/members/char/1.cc | 8 +- .../testsuite/22_locale/messages/members/char/2.cc | 8 +- .../testsuite/22_locale/messages/members/char/3.cc | 8 +- .../testsuite/22_locale/messages_byname/1.cc | 8 +- .../testsuite/22_locale/money_get/get/char/1.cc | 8 +- .../testsuite/22_locale/money_get/get/char/2.cc | 8 +- .../testsuite/22_locale/money_get/get/char/3.cc | 8 +- .../testsuite/22_locale/money_get/get/char/4.cc | 8 +- .../testsuite/22_locale/money_get/get/wchar_t/1.cc | 6 +- .../testsuite/22_locale/money_get/get/wchar_t/2.cc | 6 +- .../testsuite/22_locale/money_get/get/wchar_t/3.cc | 6 +- .../testsuite/22_locale/money_get/get/wchar_t/4.cc | 6 +- .../testsuite/22_locale/money_put/put/char/1.cc | 8 +- .../testsuite/22_locale/money_put/put/char/2.cc | 8 +- .../testsuite/22_locale/money_put/put/char/3.cc | 8 +- .../testsuite/22_locale/money_put/put/wchar_t/1.cc | 6 +- .../testsuite/22_locale/money_put/put/wchar_t/2.cc | 6 +- .../testsuite/22_locale/money_put/put/wchar_t/3.cc | 6 +- .../22_locale/moneypunct/members/char/2.cc | 4 +- .../22_locale/moneypunct/members/wchar_t/2.cc | 2 +- .../testsuite/22_locale/moneypunct_byname/1.cc | 9 +- .../testsuite/22_locale/num_get/get/char/1.cc | 8 +- .../testsuite/22_locale/num_get/get/char/2.cc | 8 +- .../testsuite/22_locale/num_get/get/char/3.cc | 8 +- .../testsuite/22_locale/num_get/get/char/5.cc | 4 +- .../testsuite/22_locale/num_get/get/char/6.cc | 4 +- .../testsuite/22_locale/num_get/get/wchar_t/1.cc | 6 +- .../testsuite/22_locale/num_get/get/wchar_t/2.cc | 6 +- .../testsuite/22_locale/num_get/get/wchar_t/3.cc | 6 +- .../testsuite/22_locale/num_get/get/wchar_t/5.cc | 2 +- .../testsuite/22_locale/num_get/get/wchar_t/6.cc | 2 +- .../testsuite/22_locale/num_put/put/char/1.cc | 8 +- .../testsuite/22_locale/num_put/put/char/2.cc | 8 +- .../testsuite/22_locale/num_put/put/char/3.cc | 8 +- .../testsuite/22_locale/num_put/put/char/5.cc | 4 +- .../testsuite/22_locale/num_put/put/wchar_t/1.cc | 6 +- .../testsuite/22_locale/num_put/put/wchar_t/2.cc | 6 +- .../testsuite/22_locale/num_put/put/wchar_t/3.cc | 6 +- .../testsuite/22_locale/num_put/put/wchar_t/5.cc | 2 +- .../testsuite/22_locale/numpunct/members/char/1.cc | 8 +- .../testsuite/22_locale/numpunct/members/char/2.cc | 8 +- .../22_locale/numpunct/members/wchar_t/1.cc | 6 +- .../22_locale/numpunct/members/wchar_t/2.cc | 6 +- .../testsuite/22_locale/numpunct_byname/1.cc | 8 +- .../testsuite/22_locale/numpunct_byname/2.cc | 4 +- .../22_locale/time_get/date_order/char/1.cc | 8 +- .../22_locale/time_get/date_order/wchar_t/1.cc | 6 +- .../22_locale/time_get/get_date/char/1.cc | 8 +- .../22_locale/time_get/get_date/char/2.cc | 8 +- .../22_locale/time_get/get_date/wchar_t/1.cc | 6 +- .../22_locale/time_get/get_date/wchar_t/2.cc | 6 +- .../22_locale/time_get/get_monthname/char/1.cc | 8 +- .../22_locale/time_get/get_monthname/char/2.cc | 8 +- .../22_locale/time_get/get_monthname/wchar_t/1.cc | 6 +- .../22_locale/time_get/get_monthname/wchar_t/2.cc | 6 +- .../22_locale/time_get/get_time/char/1.cc | 8 +- .../22_locale/time_get/get_time/char/2.cc | 8 +- .../22_locale/time_get/get_time/wchar_t/1.cc | 6 +- .../22_locale/time_get/get_time/wchar_t/2.cc | 6 +- .../22_locale/time_get/get_weekday/char/1.cc | 8 +- .../22_locale/time_get/get_weekday/char/2.cc | 8 +- .../22_locale/time_get/get_weekday/wchar_t/1.cc | 6 +- .../22_locale/time_get/get_weekday/wchar_t/2.cc | 6 +- .../22_locale/time_get/get_year/char/1.cc | 8 +- .../22_locale/time_get/get_year/wchar_t/1.cc | 6 +- .../testsuite/22_locale/time_put/put/char/1.cc | 8 +- .../testsuite/22_locale/time_put/put/char/2.cc | 8 +- .../testsuite/22_locale/time_put/put/char/3.cc | 8 +- .../testsuite/22_locale/time_put/put/char/4.cc | 8 +- .../testsuite/22_locale/time_put/put/char/5.cc | 8 +- .../testsuite/22_locale/time_put/put/char/6.cc | 8 +- .../testsuite/22_locale/time_put/put/char/7.cc | 8 +- .../testsuite/22_locale/time_put/put/char/8.cc | 8 +- .../testsuite/22_locale/time_put/put/wchar_t/1.cc | 6 +- .../testsuite/22_locale/time_put/put/wchar_t/2.cc | 6 +- .../testsuite/22_locale/time_put/put/wchar_t/3.cc | 6 +- .../testsuite/22_locale/time_put/put/wchar_t/4.cc | 6 +- .../testsuite/22_locale/time_put/put/wchar_t/5.cc | 6 +- .../testsuite/22_locale/time_put/put/wchar_t/6.cc | 6 +- .../testsuite/22_locale/time_put/put/wchar_t/7.cc | 6 +- .../testsuite/22_locale/time_put/put/wchar_t/8.cc | 6 +- .../27_io/basic_filebuf/imbue/char/9322.cc | 6 +- .../testsuite/27_io/basic_ios/copyfmt/char/2.cc | 4 +- .../basic_ostream/inserters_arithmetic/char/2.cc | 4 +- .../27_io/basic_streambuf/imbue/char/9322.cc | 6 +- .../27_io/basic_stringbuf/imbue/char/9322.cc | 6 +- libstdc++-v3/testsuite/testsuite_hooks.cc | 49 ++----- libstdc++-v3/testsuite/testsuite_hooks.h | 7 +- 144 files changed, 643 insertions(+), 471 deletions(-) diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 9d14062..57bac9c 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,160 @@ +2003-04-14 Andreas Tobler + Benjamin Kosnik + + * config/os/generic/ctype_inline.h: Fix. + +2003-04-14 Benjamin Kosnik + + * testsuite/testsuite_hooks.h + (__gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher): + Change to run_named_locale_test. + * testsuite/testsuite_hooks.cc (__gnu_cxx_test): Same. + + * testsuite/22_locale/codecvt/always_noconv/wchar_t/2.cc: Use + run_test_named_locale. + * testsuite/22_locale/codecvt/always_noconv/wchar_t/3.cc: Same. + * testsuite/22_locale/codecvt/always_noconv/wchar_t/4.cc: Same. + * testsuite/22_locale/codecvt/encoding/wchar_t/2.cc: Same. + * testsuite/22_locale/codecvt/encoding/wchar_t/3.cc: Same. + * testsuite/22_locale/codecvt/encoding/wchar_t/4.cc: Same. + * testsuite/22_locale/codecvt/in/wchar_t/2.cc: Same. + * testsuite/22_locale/codecvt/in/wchar_t/3.cc: Same. + * testsuite/22_locale/codecvt/in/wchar_t/4.cc: Same. + * testsuite/22_locale/codecvt/in/wchar_t/7.cc: Same. + * testsuite/22_locale/codecvt/in/wchar_t/8.cc: Same. + * testsuite/22_locale/codecvt/in/wchar_t/9.cc: Same. + * testsuite/22_locale/codecvt/length/wchar_t/2.cc: Same. + * testsuite/22_locale/codecvt/length/wchar_t/3.cc: Same. + * testsuite/22_locale/codecvt/length/wchar_t/4.cc: Same. + * testsuite/22_locale/codecvt/length/wchar_t/7.cc: Same. + * testsuite/22_locale/codecvt/max_length/wchar_t/2.cc: Same. + * testsuite/22_locale/codecvt/max_length/wchar_t/3.cc: Same. + * testsuite/22_locale/codecvt/max_length/wchar_t/4.cc: Same. + * testsuite/22_locale/codecvt/out/wchar_t/2.cc: Same. + * testsuite/22_locale/codecvt/out/wchar_t/3.cc: Same. + * testsuite/22_locale/codecvt/out/wchar_t/4.cc: Same. + * testsuite/22_locale/codecvt/out/wchar_t/7.cc: Same. + * testsuite/22_locale/codecvt/unshift/wchar_t/2.cc: Same. + * testsuite/22_locale/codecvt/unshift/wchar_t/3.cc: Same. + * testsuite/22_locale/codecvt/unshift/wchar_t/4.cc: Same. + * testsuite/22_locale/collate/compare/char/1.cc: Same. + * testsuite/22_locale/collate/compare/char/2.cc: Same. + * testsuite/22_locale/collate/compare/char/3.cc: Same. + * testsuite/22_locale/collate/compare/wchar_t/1.cc: Same. + * testsuite/22_locale/collate/compare/wchar_t/2.cc: Same. + * testsuite/22_locale/collate/compare/wchar_t/3.cc: Same. + * testsuite/22_locale/collate/hash/char/2.cc: Same. + * testsuite/22_locale/collate/hash/wchar_t/2.cc: Same. + * testsuite/22_locale/collate/transform/char/2.cc: Same. + * testsuite/22_locale/collate/transform/char/3.cc: Same. + * testsuite/22_locale/collate/transform/wchar_t/2.cc: Same. + * testsuite/22_locale/collate/transform/wchar_t/3.cc: Same. + * testsuite/22_locale/collate_byname/1.cc: Same. + * testsuite/22_locale/ctype/is/char/2.cc: Same. + * testsuite/22_locale/ctype/is/wchar_t/2.cc: Same. + * testsuite/22_locale/ctype/narrow/wchar_t/3.cc: Same. + * testsuite/22_locale/ctype/widen/wchar_t/2.cc: Same. + * testsuite/22_locale/ctype/widen/wchar_t/3.cc: Same. + * testsuite/22_locale/facet/2.cc: Same. + * testsuite/22_locale/locale/cons/2.cc: Same. + * testsuite/22_locale/locale/cons/4.cc: Same. + * testsuite/22_locale/locale/cons/5.cc: Same. + * testsuite/22_locale/locale/cons/7.cc: Same. + * testsuite/22_locale/locale/cons/7222-c.cc: Same. + * testsuite/22_locale/locale/cons/7222-env.cc: Same. + * testsuite/22_locale/locale/global_locale_objects/2.cc: Same. + * testsuite/22_locale/messages/members/char/1.cc: Same. + * testsuite/22_locale/messages/members/char/2.cc: Same. + * testsuite/22_locale/messages/members/char/3.cc: Same. + * testsuite/22_locale/messages_byname/1.cc: Same. + * testsuite/22_locale/money_get/get/char/1.cc: Same. + * testsuite/22_locale/money_get/get/char/2.cc: Same. + * testsuite/22_locale/money_get/get/char/3.cc: Same. + * testsuite/22_locale/money_get/get/char/4.cc: Same. + * testsuite/22_locale/money_get/get/wchar_t/1.cc: Same. + * testsuite/22_locale/money_get/get/wchar_t/2.cc: Same. + * testsuite/22_locale/money_get/get/wchar_t/3.cc: Same. + * testsuite/22_locale/money_get/get/wchar_t/4.cc: Same. + * testsuite/22_locale/money_put/put/char/1.cc: Same. + * testsuite/22_locale/money_put/put/char/2.cc: Same. + * testsuite/22_locale/money_put/put/char/3.cc: Same. + * testsuite/22_locale/money_put/put/wchar_t/1.cc: Same. + * testsuite/22_locale/money_put/put/wchar_t/2.cc: Same. + * testsuite/22_locale/money_put/put/wchar_t/3.cc: Same. + * testsuite/22_locale/moneypunct/members/char/2.cc: Same. + * testsuite/22_locale/moneypunct/members/wchar_t/2.cc: Same. + * testsuite/22_locale/moneypunct_byname/1.cc: Same. + * testsuite/22_locale/num_get/get/char/1.cc: Same. + * testsuite/22_locale/num_get/get/char/2.cc: Same. + * testsuite/22_locale/num_get/get/char/3.cc: Same. + * testsuite/22_locale/num_get/get/char/5.cc: Same. + * testsuite/22_locale/num_get/get/char/6.cc: Same. + * testsuite/22_locale/num_get/get/wchar_t/1.cc: Same. + * testsuite/22_locale/num_get/get/wchar_t/2.cc: Same. + * testsuite/22_locale/num_get/get/wchar_t/3.cc: Same. + * testsuite/22_locale/num_get/get/wchar_t/5.cc: Same. + * testsuite/22_locale/num_get/get/wchar_t/6.cc: Same. + * testsuite/22_locale/num_put/put/char/1.cc: Same. + * testsuite/22_locale/num_put/put/char/2.cc: Same. + * testsuite/22_locale/num_put/put/char/3.cc: Same. + * testsuite/22_locale/num_put/put/char/5.cc: Same. + * testsuite/22_locale/num_put/put/wchar_t/1.cc: Same. + * testsuite/22_locale/num_put/put/wchar_t/2.cc: Same. + * testsuite/22_locale/num_put/put/wchar_t/3.cc: Same. + * testsuite/22_locale/num_put/put/wchar_t/5.cc: Same. + * testsuite/22_locale/numpunct/members/char/1.cc: Same. + * testsuite/22_locale/numpunct/members/char/2.cc: Same. + * testsuite/22_locale/numpunct/members/wchar_t/1.cc: Same. + * testsuite/22_locale/numpunct/members/wchar_t/2.cc: Same. + * testsuite/22_locale/numpunct_byname/1.cc: Same. + * testsuite/22_locale/numpunct_byname/2.cc: Same. + * testsuite/22_locale/time_get/date_order/char/1.cc: Same. + * testsuite/22_locale/time_get/date_order/wchar_t/1.cc: Same. + * testsuite/22_locale/time_get/get_date/char/1.cc: Same. + * testsuite/22_locale/time_get/get_date/char/2.cc: Same. + * testsuite/22_locale/time_get/get_date/wchar_t/1.cc: Same. + * testsuite/22_locale/time_get/get_date/wchar_t/2.cc: Same. + * testsuite/22_locale/time_get/get_monthname/char/1.cc: Same. + * testsuite/22_locale/time_get/get_monthname/char/2.cc: Same. + * testsuite/22_locale/time_get/get_monthname/wchar_t/1.cc: Same. + * testsuite/22_locale/time_get/get_monthname/wchar_t/2.cc: Same. + * testsuite/22_locale/time_get/get_time/char/1.cc: Same. + * testsuite/22_locale/time_get/get_time/char/2.cc: Same. + * testsuite/22_locale/time_get/get_time/wchar_t/1.cc: Same. + * testsuite/22_locale/time_get/get_time/wchar_t/2.cc: Same. + * testsuite/22_locale/time_get/get_weekday/char/1.cc: Same. + * testsuite/22_locale/time_get/get_weekday/char/2.cc: Same. + * testsuite/22_locale/time_get/get_weekday/wchar_t/1.cc: Same. + * testsuite/22_locale/time_get/get_weekday/wchar_t/2.cc: Same. + * testsuite/22_locale/time_get/get_year/char/1.cc: Same. + * testsuite/22_locale/time_get/get_year/wchar_t/1.cc: Same. + * testsuite/22_locale/time_put/put/char/1.cc: Same. + * testsuite/22_locale/time_put/put/char/2.cc: Same. + * testsuite/22_locale/time_put/put/char/3.cc: Same. + * testsuite/22_locale/time_put/put/char/4.cc: Same. + * testsuite/22_locale/time_put/put/char/5.cc: Same. + * testsuite/22_locale/time_put/put/char/6.cc: Same. + * testsuite/22_locale/time_put/put/char/7.cc: Same. + * testsuite/22_locale/time_put/put/char/8.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/1.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/2.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/3.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/4.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/5.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/6.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/7.cc: Same. + * testsuite/22_locale/time_put/put/wchar_t/8.cc: Same. + * testsuite/27_io/basic_filebuf/imbue/char/9322.cc: Same. + * testsuite/27_io/basic_ios/copyfmt/char/2.cc: Same. + * testsuite/27_io/basic_ostream/inserters_arithmetic/char/2.cc: Same. + * testsuite/27_io/basic_streambuf/imbue/char/9322.cc: Same. + * testsuite/27_io/basic_stringbuf/imbue/char/9322.cc: Same. + +2003-04-14 Andreas Tobler + + * configure.target (_cpu_incdir_fullpath): Solaris 2.9 uses + solaris includes, not generic. + 2003-04-14 Loren J. Rittle * testsuite/26_numerics/c99_classification_macros_c.cc: Add XFAIL. diff --git a/libstdc++-v3/config/locale/generic/c_locale.cc b/libstdc++-v3/config/locale/generic/c_locale.cc index 13bc21a..48d406f 100644 --- a/libstdc++-v3/config/locale/generic/c_locale.cc +++ b/libstdc++-v3/config/locale/generic/c_locale.cc @@ -1,6 +1,6 @@ // Wrapper for underlying C-language localization -*- C++ -*- -// Copyright (C) 2001, 2002 Free Software Foundation, Inc. +// Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -216,7 +216,7 @@ namespace std __c_locale) { __cloc = NULL; - if (strcmp (__s, "C")) + if (strcmp(__s, "C")) __throw_runtime_error("attempt to create locale from unhandled name in generic implementation; see http://gcc.gnu.org/ml/libstdc++/2003-02/msg00345.html"); } diff --git a/libstdc++-v3/config/os/generic/ctype_inline.h b/libstdc++-v3/config/os/generic/ctype_inline.h index c10cb56..be43c47 100644 --- a/libstdc++-v3/config/os/generic/ctype_inline.h +++ b/libstdc++-v3/config/os/generic/ctype_inline.h @@ -1,6 +1,6 @@ // Locale support -*- C++ -*- -// Copyright (C) 2000 Free Software Foundation, Inc. +// Copyright (C) 2000, 2003 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -39,69 +39,95 @@ // functionality should be added for the native os in question: see // the config/os/bits/ctype_*.h files. +// Constructing a synthetic "C" table should be seriously considered... + bool ctype:: is(mask __m, char __c) const { - bool __ret; - switch (__m) + if (_M_table) + return _M_table[static_cast(__c)] & __m; + else { - case space: - __ret = isspace(__c); - break; - case print: - __ret = isprint(__c); - break; - case cntrl: - __ret = iscntrl(__c); - break; - case upper: - __ret = isupper(__c); - break; - case lower: - __ret = islower(__c); - break; - case alpha: - __ret = isalpha(__c); - break; - case digit: - __ret = isdigit(__c); - break; - case punct: - __ret = ispunct(__c); - break; - case xdigit: - __ret = isxdigit(__c); - break; - case alnum: - __ret = isalnum(__c); - break; - case graph: - __ret = isgraph(__c); - break; - default: - __ret = false; - break; + bool __ret = true; + const int __bitmasksize = 11; + int __bitcur = 0; // Lowest bitmask in ctype_base == 0 + for (;__ret && __bitcur < __bitmasksize; ++__bitcur) + { + mask __bit = static_cast(1 << __bitcur); + if (__m & __bit) + { + bool __testis; + switch (__bit) + { + case space: + __testis = isspace(__c); + break; + case print: + __testis = isprint(__c); + break; + case cntrl: + __testis = iscntrl(__c); + break; + case upper: + __testis = isupper(__c); + break; + case lower: + __testis = islower(__c); + break; + case alpha: + __testis = isalpha(__c); + break; + case digit: + __testis = isdigit(__c); + break; + case punct: + __testis = ispunct(__c); + break; + case xdigit: + __testis = isxdigit(__c); + break; + case alnum: + __testis = isalnum(__c); + break; + case graph: + __testis = isgraph(__c); + break; + default: + __testis = false; + break; + } + __ret &= __testis; + } + } + return __ret; } - return __ret; } const char* ctype:: is(const char* __low, const char* __high, mask* __vec) const { - const int __bitmasksize = 11; // Highest bitmask in ctype_base == 10 - for (;__low < __high; ++__vec, ++__low) + if (_M_table) + while (__low < __high) + *__vec++ = _M_table[static_cast(*__low++)]; + else { - mask __m = 0; - int __i = 0; // Lowest bitmask in ctype_base == 0 - for (;__i < __bitmasksize; ++__i) + // Highest bitmask in ctype_base == 10. + const int __bitmasksize = 11; + for (;__low < __high; ++__vec, ++__low) { - mask __bit = static_cast(1 << __i); - if (this->is(__bit, *__low)) - __m |= __bit; + mask __m = 0; + // Lowest bitmask in ctype_base == 0 + int __i = 0; + for (;__i < __bitmasksize; ++__i) + { + mask __bit = static_cast(1 << __i); + if (this->is(__bit, *__low)) + __m |= __bit; + } + *__vec = __m; } - *__vec = __m; } return __high; } @@ -110,8 +136,13 @@ ctype:: scan_is(mask __m, const char* __low, const char* __high) const { - while (__low < __high && !this->is(__m, *__low)) - ++__low; + if (_M_table) + while (__low < __high + && !(_M_table[static_cast(*__low)] & __m)) + ++__low; + else + while (__low < __high && !this->is(__m, *__low)) + ++__low; return __low; } @@ -119,7 +150,12 @@ ctype:: scan_not(mask __m, const char* __low, const char* __high) const { - while (__low < __high && this->is(__m, *__low) != 0) - ++__low; + if (_M_table) + while (__low < __high + && (_M_table[static_cast(*__low)] & __m) != 0) + ++__low; + else + while (__low < __high && this->is(__m, *__low) != 0) + ++__low; return __low; } diff --git a/libstdc++-v3/configure.target b/libstdc++-v3/configure.target index a186659..526d300 100644 --- a/libstdc++-v3/configure.target +++ b/libstdc++-v3/configure.target @@ -166,7 +166,7 @@ case "${target_os}" in solaris2.6*) os_include_dir="os/solaris/solaris2.6" ;; - solaris2.[78]*) + solaris2.[789]*) os_include_dir="os/solaris/solaris2.7" ;; windiss*) diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/2.cc index 07b3a2d..d7e72d6 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/2.cc @@ -33,7 +33,7 @@ void test02() bool test = true; typedef codecvt w_codecvt; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/3.cc index b44e86f..ad45e62 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/3.cc @@ -33,7 +33,7 @@ void test03() bool test = true; typedef codecvt w_codecvt; - locale loc ("en_US.ISO-8859-15"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-15"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/4.cc index 15a8546..fe72e34 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/always_noconv/wchar_t/4.cc @@ -33,7 +33,7 @@ void test04() bool test = true; typedef codecvt w_codecvt; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/2.cc index 9c7f5d0..c3eca4ae 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/2.cc @@ -33,7 +33,7 @@ void test02() typedef codecvt w_codecvt; bool test = true; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/3.cc index 98a8961..8297c26 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/3.cc @@ -33,7 +33,7 @@ void test03() typedef codecvt w_codecvt; bool test = true; - locale loc ("en_US.ISO-8859-15"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-15"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/4.cc index f2ada10..2ffc351 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/encoding/wchar_t/4.cc @@ -33,7 +33,7 @@ void test04() typedef codecvt w_codecvt; bool test = true; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/2.cc index d9e55ef..a7a622f 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/2.cc @@ -88,7 +88,7 @@ void test02() wmemset(i_ref, 0xdeadbeef, size + 1); int_type* ito_next; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/3.cc index 152e7e9..1279d3b 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/3.cc @@ -102,7 +102,7 @@ void test03() wmemset(i_ref, 0xdeadbeef, size + 1); int_type* ito_next; - locale loc ("en_US.ISO-8859-15"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-15"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/4.cc index c916a16..a4ef7fe 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/4.cc @@ -110,7 +110,7 @@ void test04() wmemset(i_ref, 0xdeadbeef, esize + 1); int_type* ito_next; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/7.cc b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/7.cc index f692e9c..799414b 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/7.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/7.cc @@ -60,7 +60,7 @@ void test07() wmemset(i_ref, 0xdeadbeef, size + 1); int_type* ito_next; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/8.cc b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/8.cc index 28b1fa0..27a59c6 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/8.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/8.cc @@ -109,7 +109,7 @@ void test08() wmemset(i_ref, 0xdeadbeef, esize + 1); int_type* ito_next; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/9.cc b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/9.cc index 0ddebc7..f95a436 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/9.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/in/wchar_t/9.cc @@ -111,7 +111,7 @@ void test09() int_type* ito = i_arr; int_type* ito_next; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/2.cc index 0e90fbd..029e30f 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/2.cc @@ -61,7 +61,7 @@ void test02() "\xff"; int size = strlen(e_lit); - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/3.cc index 8031c3e..41555de 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/3.cc @@ -61,7 +61,7 @@ void test03() "\xff"; int size = strlen(e_lit); - locale loc ("en_US.ISO-8859-15"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-15"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/4.cc index 6a802bd..f49e47d 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/4.cc @@ -100,7 +100,7 @@ void test04() int esize = strlen(e_lit); int isize = wcslen(i_lit); - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/7.cc b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/7.cc index 8a275e3..485bfe0 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/7.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/length/wchar_t/7.cc @@ -52,7 +52,7 @@ void test07() const ext_type* efrom_next; int size = strlen(e_lit); - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/2.cc index 9c76752..efa390b 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/2.cc @@ -31,7 +31,7 @@ void test02() bool test = true; typedef codecvt w_codecvt; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/3.cc index 2d312bd..5087784 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/3.cc @@ -31,7 +31,7 @@ void test03() bool test = true; typedef codecvt w_codecvt; - locale loc ("en_US.ISO-8859-15"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-15"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/4.cc index cd4d08d..2e2a62e 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/max_length/wchar_t/4.cc @@ -31,7 +31,7 @@ void test04() bool test = true; typedef codecvt w_codecvt; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/2.cc index c2e807d..bb172db 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/2.cc @@ -86,7 +86,7 @@ void test02() memset(e_ref, 0xf0, size + 1); ext_type* eto_next; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/3.cc index d92e01c..8d396f8 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/3.cc @@ -100,7 +100,7 @@ void test03() memset(e_ref, 0xf0, size + 1); ext_type* eto_next; - locale loc ("en_US.ISO-8859-15"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-15"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/4.cc index 626ff70..1a28aa7 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/4.cc @@ -107,7 +107,7 @@ void test04() memset(e_ref, 0xf0, esize + 1); ext_type* eto_next; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/7.cc b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/7.cc index 3ea57c0..7b5c120 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/7.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/out/wchar_t/7.cc @@ -58,7 +58,7 @@ void test03() memset(e_ref, 0xf0, size + 1); ext_type* eto_next; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/2.cc index 77e3b92..5bd81df 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/2.cc @@ -71,7 +71,7 @@ void test02() memset(e_ref, 0xf0, size + 1); ext_type* eto_next; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/3.cc index a828090..167e123 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/3.cc @@ -85,7 +85,7 @@ void test03() memset(e_ref, 0xf0, size + 1); ext_type* eto_next; - locale loc ("en_US.ISO-8859-15"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-15"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/4.cc index 09a91ed..631b873 100644 --- a/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/codecvt/unshift/wchar_t/4.cc @@ -80,7 +80,7 @@ void test04() memset(e_ref, 0xf0, size + 1); ext_type* eto_next; - locale loc ("en_US.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.UTF-8"); locale::global(loc); const w_codecvt* cvt = &use_facet(loc); diff --git a/libstdc++-v3/testsuite/22_locale/collate/compare/char/1.cc b/libstdc++-v3/testsuite/22_locale/collate/compare/char/1.cc index bed2fb4..fd4c90d 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/compare/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/compare/char/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -74,6 +74,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/collate/compare/char/2.cc b/libstdc++-v3/testsuite/22_locale/collate/compare/char/2.cc index ab29ac4..892bac5 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/compare/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/compare/char/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -81,6 +81,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/collate/compare/char/3.cc b/libstdc++-v3/testsuite/22_locale/collate/compare/char/3.cc index c820954..e604b20 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/compare/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/compare/char/3.cc @@ -33,7 +33,7 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); // cache the collate facets @@ -85,6 +85,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/1.cc index 0ba7b05..b74157b 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/2.cc index 24b327f..67ab49d 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/3.cc index 0f9ee64..824f8e1 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/compare/wchar_t/3.cc @@ -33,7 +33,7 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); // cache the collate facets diff --git a/libstdc++-v3/testsuite/22_locale/collate/hash/char/2.cc b/libstdc++-v3/testsuite/22_locale/collate/hash/char/2.cc index 47fcd57..5e83368 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/hash/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/hash/char/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -70,6 +70,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/collate/hash/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/collate/hash/wchar_t/2.cc index b11be4a..79e3267 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/hash/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/hash/wchar_t/2.cc @@ -32,9 +32,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/collate/transform/char/2.cc b/libstdc++-v3/testsuite/22_locale/collate/transform/char/2.cc index 24ff7cd..4a38327 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/transform/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/transform/char/2.cc @@ -32,9 +32,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -67,6 +67,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/collate/transform/char/3.cc b/libstdc++-v3/testsuite/22_locale/collate/transform/char/3.cc index f9d16b5..21b90ff 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/transform/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/transform/char/3.cc @@ -32,7 +32,7 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); // cache the collate facets @@ -88,6 +88,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/2.cc index f643fd6..274d78c 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/2.cc @@ -32,9 +32,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/3.cc index 108c0a4..0a3f981 100644 --- a/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/collate/transform/wchar_t/3.cc @@ -32,7 +32,7 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); // cache the collate facets diff --git a/libstdc++-v3/testsuite/22_locale/collate_byname/1.cc b/libstdc++-v3/testsuite/22_locale/collate_byname/1.cc index edfb42c..eec1513 100644 --- a/libstdc++-v3/testsuite/22_locale/collate_byname/1.cc +++ b/libstdc++-v3/testsuite/22_locale/collate_byname/1.cc @@ -32,12 +32,12 @@ void test01() string str; locale loc_c = locale::classic(); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); + str = loc_de.name(); + locale loc_byname(locale::classic(), new collate_byname("de_DE")); str = loc_byname.name(); - locale loc_de("de_DE"); - str = loc_de.name(); - VERIFY( loc_de != loc_byname ); // cache the collate facets @@ -131,6 +131,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/ctype/is/char/2.cc b/libstdc++-v3/testsuite/22_locale/ctype/is/char/2.cc index d04800a..605e5f3 100644 --- a/libstdc++-v3/testsuite/22_locale/ctype/is/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/ctype/is/char/2.cc @@ -67,7 +67,7 @@ void test02() } // "de_DE" - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); const ctype& ctype_de = use_facet >(loc_de); for (int i = 0; i < max; ++i) { @@ -99,6 +99,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/ctype/is/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/ctype/is/wchar_t/2.cc index b1b565f..7ff278c 100644 --- a/libstdc++-v3/testsuite/22_locale/ctype/is/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/ctype/is/wchar_t/2.cc @@ -67,7 +67,7 @@ void test02() } // "de_DE" - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); const ctype& ctype_de = use_facet >(loc_de); for (int i = 0; i < max; ++i) { diff --git a/libstdc++-v3/testsuite/22_locale/ctype/narrow/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/ctype/narrow/wchar_t/3.cc index f235d8a..67d9b6e 100644 --- a/libstdc++-v3/testsuite/22_locale/ctype/narrow/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/ctype/narrow/wchar_t/3.cc @@ -38,7 +38,7 @@ void test03() using namespace std; bool test = true; - locale loc ("se_NO.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("se_NO.UTF-8"); const ctype& wct = use_facet >(loc); const wchar_t* wstrlit = L"\x80"; diff --git a/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/2.cc index e4e4967..e1ab3f7 100644 --- a/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/2.cc @@ -38,7 +38,7 @@ void test02() using namespace std; bool test = true; - locale loc ("en_US.ISO-8859-1"); + locale loc = __gnu_cxx_test::try_named_locale("en_US.ISO-8859-1"); const ctype& wct = use_facet >(loc); char c = 0xff; diff --git a/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/3.cc index e872a94..1d380d4 100644 --- a/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/ctype/widen/wchar_t/3.cc @@ -38,7 +38,7 @@ void test03() using namespace std; bool test = true; - locale loc ("se_NO.UTF-8"); + locale loc = __gnu_cxx_test::try_named_locale("se_NO.UTF-8"); const ctype& wct = use_facet >(loc); const char* strlit = "\xc2\x80"; diff --git a/libstdc++-v3/testsuite/22_locale/facet/2.cc b/libstdc++-v3/testsuite/22_locale/facet/2.cc index ea63d73..379ed89 100644 --- a/libstdc++-v3/testsuite/22_locale/facet/2.cc +++ b/libstdc++-v3/testsuite/22_locale/facet/2.cc @@ -83,12 +83,12 @@ void test02() // 4: Named locale should destroy facets when it goes out of scope. // Not quite sure how to test for this w/o valgrind at the moment. { - locale loc03("es_MX"); + locale loc03 = __gnu_cxx_test::try_named_locale("es_MX"); } } int main () { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/locale/cons/2.cc b/libstdc++-v3/testsuite/22_locale/locale/cons/2.cc index 1f13c23..1c03e4d 100644 --- a/libstdc++-v3/testsuite/22_locale/locale/cons/2.cc +++ b/libstdc++-v3/testsuite/22_locale/locale/cons/2.cc @@ -80,7 +80,7 @@ namespace std static char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) - { return static_cast(memcpy(__s1, __s2, __n)); } + { return static_cast(memcpy(__s1, __s2, __n)); } static char_type* assign(char_type* __s, size_t __n, char_type __a); @@ -170,7 +170,7 @@ void test01() // 3 // explicit locale(const char* std_name) - locale loc06("fr_FR"); + locale loc06 = __gnu_cxx_test::try_named_locale("fr_FR"); VERIFY (loc06 != loc01); VERIFY (loc06 != loc02); VERIFY (loc06.name() == "fr_FR"); diff --git a/libstdc++-v3/testsuite/22_locale/locale/cons/4.cc b/libstdc++-v3/testsuite/22_locale/locale/cons/4.cc index 4864b0b..f20542a 100644 --- a/libstdc++-v3/testsuite/22_locale/locale/cons/4.cc +++ b/libstdc++-v3/testsuite/22_locale/locale/cons/4.cc @@ -33,7 +33,7 @@ void test03() const char* LC_ALL_orig = getenv("LC_ALL"); if (!setenv("LC_ALL", "it_IT", 1)) { - std::locale loc(""); + std::locale loc = __gnu_cxx_test::try_named_locale(""); VERIFY( loc.name() == "it_IT" ); setenv("LC_ALL", LC_ALL_orig ? LC_ALL_orig : "", 1); } @@ -42,6 +42,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/locale/cons/5.cc b/libstdc++-v3/testsuite/22_locale/locale/cons/5.cc index 5c649d0..55ace6e 100644 --- a/libstdc++-v3/testsuite/22_locale/locale/cons/5.cc +++ b/libstdc++-v3/testsuite/22_locale/locale/cons/5.cc @@ -65,7 +65,7 @@ void test04() // Check that a "POSIX" LC_ALL is equivalent to "C". if (!setenv("LC_ALL", "POSIX", 1)) { - locale loc(""); + locale loc = __gnu_cxx_test::try_named_locale(""); VERIFY( loc.name() == "C" ); } setenv("LC_ALL", "", 1); @@ -73,7 +73,7 @@ void test04() // Check that a "en_PH" LC_ALL is equivalent to "en_PH". if (!setenv("LC_ALL", "en_PH", 1)) { - locale loc(""); + locale loc = __gnu_cxx_test::try_named_locale(""); VERIFY( loc.name() == "en_PH" ); } setenv("LC_ALL", "", 1); @@ -83,7 +83,7 @@ void test04() { if (!setenv("LC_ALL", "en_PH", 1)) { - locale loc(""); + locale loc = __gnu_cxx_test::try_named_locale(""); VERIFY( loc.name() == "en_PH" ); } setenv("LC_ALL", "", 1); @@ -112,7 +112,7 @@ void test04() // Check the default set by LANG. if (!setenv("LANG", "fr_FR", 1)) { - locale loc(""); + locale loc = __gnu_cxx_test::try_named_locale(""); VERIFY( loc.name() == "fr_FR" ); } @@ -126,7 +126,7 @@ void test04() // Setting a category in the "C" default. if (!setenv("LC_COLLATE", "de_DE", 1)) { - locale loc(""); + locale loc = __gnu_cxx_test::try_named_locale(""); #if _GLIBCPP_NUM_CATEGORIES VERIFY( loc.name() == "LC_CTYPE=C;LC_NUMERIC=C;LC_TIME=C;" @@ -142,7 +142,7 @@ void test04() // Changing the LANG default while LC_COLLATE is set. if (!setenv("LANG", "fr_FR", 1)) { - locale loc(""); + locale loc = __gnu_cxx_test::try_named_locale(""); #if _GLIBCPP_NUM_CATEGORIES VERIFY( loc.name() == "LC_CTYPE=fr_FR;LC_NUMERIC=fr_FR;" "LC_TIME=fr_FR;LC_COLLATE=de_DE;LC_MONETARY=fr_FR;" @@ -160,7 +160,7 @@ void test04() #if _GLIBCPP_NUM_CATEGORIES if (!setenv("LC_IDENTIFICATION", "it_IT", 1)) { - locale loc(""); + locale loc = __gnu_cxx_test::try_named_locale(""); VERIFY( loc.name() == "LC_CTYPE=fr_FR;LC_NUMERIC=fr_FR;" "LC_TIME=fr_FR;LC_COLLATE=de_DE;LC_MONETARY=fr_FR;" "LC_MESSAGES=fr_FR;LC_PAPER=fr_FR;LC_NAME=fr_FR;" @@ -193,6 +193,6 @@ void test04() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test04); + test04(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/locale/cons/7.cc b/libstdc++-v3/testsuite/22_locale/locale/cons/7.cc index fb70966..ced0f59 100644 --- a/libstdc++-v3/testsuite/22_locale/locale/cons/7.cc +++ b/libstdc++-v3/testsuite/22_locale/locale/cons/7.cc @@ -35,9 +35,9 @@ test02() // construct a locale object with the specialized facet. locale loc_c = locale::classic(); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); locale loc_1(locale::classic(), new numpunct_byname("fr_FR")); - locale loc_fr("fr_FR"); // check names VERIFY( loc_c.name() == name_c ); @@ -99,6 +99,6 @@ test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/locale/cons/7222-c.cc b/libstdc++-v3/testsuite/22_locale/locale/cons/7222-c.cc index 7a93dee..0034624 100644 --- a/libstdc++-v3/testsuite/22_locale/locale/cons/7222-c.cc +++ b/libstdc++-v3/testsuite/22_locale/locale/cons/7222-c.cc @@ -31,7 +31,7 @@ void test02() bool test = true; std::locale loc_c1("C"); - std::locale loc_c2 ("C"); + std::locale loc_c2("C"); VERIFY( loc_c1 == loc_c2 ); } diff --git a/libstdc++-v3/testsuite/22_locale/locale/cons/7222-env.cc b/libstdc++-v3/testsuite/22_locale/locale/cons/7222-env.cc index 1309a31..126db7d 100644 --- a/libstdc++-v3/testsuite/22_locale/locale/cons/7222-env.cc +++ b/libstdc++-v3/testsuite/22_locale/locale/cons/7222-env.cc @@ -30,13 +30,13 @@ void test02() { bool test = true; - std::locale loc_1(""); - std::locale loc_2(""); + std::locale loc_1 = __gnu_cxx_test::try_named_locale(""); + std::locale loc_2 = __gnu_cxx_test::try_named_locale(""); VERIFY( loc_1 == loc_2 ); } int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/locale/global_locale_objects/2.cc b/libstdc++-v3/testsuite/22_locale/locale/global_locale_objects/2.cc index bde35e2..7d5aec0 100644 --- a/libstdc++-v3/testsuite/22_locale/locale/global_locale_objects/2.cc +++ b/libstdc++-v3/testsuite/22_locale/locale/global_locale_objects/2.cc @@ -42,13 +42,13 @@ void test02() // named locales work. if (testph && testmx) { - const locale loc_ph(ph.c_str()); - const locale loc_mx(mx.c_str()); + const locale loc_ph = __gnu_cxx_test::try_named_locale(ph.c_str()); + const locale loc_mx = __gnu_cxx_test::try_named_locale(mx.c_str()); // Use setlocale between two calls to locale("") - const locale loc_env_1(""); + const locale loc_env_1 = __gnu_cxx_test::try_named_locale(""); setlocale(LC_ALL, ph.c_str()); - const locale loc_env_2(""); + const locale loc_env_2 = __gnu_cxx_test::try_named_locale(""); VERIFY( loc_env_1 == loc_env_2 ); // Change global locale. diff --git a/libstdc++-v3/testsuite/22_locale/messages/members/char/1.cc b/libstdc++-v3/testsuite/22_locale/messages/members/char/1.cc index 7167fad..2956ec8 100644 --- a/libstdc++-v3/testsuite/22_locale/messages/members/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/messages/members/char/1.cc @@ -35,9 +35,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -64,6 +64,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/messages/members/char/2.cc b/libstdc++-v3/testsuite/22_locale/messages/members/char/2.cc index 61ffba6..eed7efa 100644 --- a/libstdc++-v3/testsuite/22_locale/messages/members/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/messages/members/char/2.cc @@ -35,9 +35,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -64,6 +64,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/messages/members/char/3.cc b/libstdc++-v3/testsuite/22_locale/messages/members/char/3.cc index 55cf801..ad97511 100644 --- a/libstdc++-v3/testsuite/22_locale/messages/members/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/messages/members/char/3.cc @@ -35,9 +35,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -64,6 +64,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/messages_byname/1.cc b/libstdc++-v3/testsuite/22_locale/messages_byname/1.cc index e9d3217..e915c96 100644 --- a/libstdc++-v3/testsuite/22_locale/messages_byname/1.cc +++ b/libstdc++-v3/testsuite/22_locale/messages_byname/1.cc @@ -35,12 +35,12 @@ void test01() const char* dir = LOCALEDIR; locale loc_c = locale::classic(); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); + str = loc_de.name(); + locale loc_byname(locale::classic(), new messages_byname("de_DE")); str = loc_byname.name(); - locale loc_de("de_DE"); - str = loc_de.name(); - VERIFY( loc_de != loc_byname ); // cache the messages facets @@ -73,6 +73,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/char/1.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/char/1.cc index f4e5481..b35b448 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/char/1.cc @@ -36,9 +36,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -146,6 +146,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/char/2.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/char/2.cc index 42e1496..a0d4cae 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/char/2.cc @@ -36,9 +36,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -135,6 +135,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/char/3.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/char/3.cc index 749c68c..80e47c9 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/char/3.cc @@ -36,9 +36,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -91,6 +91,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/char/4.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/char/4.cc index b245665..b62e2f4 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/char/4.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/char/4.cc @@ -36,9 +36,9 @@ void test04() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -86,6 +86,6 @@ void test04() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test04); + test04(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/1.cc index d8d86f2..8d1d532 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/1.cc @@ -36,9 +36,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/2.cc index 9b3c874..38721ce 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/2.cc @@ -36,9 +36,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/3.cc index 747b494..da33d63 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/3.cc @@ -36,9 +36,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/4.cc index 030c47a..91b05cb 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/get/wchar_t/4.cc @@ -36,9 +36,9 @@ void test04() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/money_put/put/char/1.cc b/libstdc++-v3/testsuite/22_locale/money_put/put/char/1.cc index d34d3fb..27d79dc 100644 --- a/libstdc++-v3/testsuite/22_locale/money_put/put/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/money_put/put/char/1.cc @@ -36,9 +36,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -124,6 +124,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_put/put/char/2.cc b/libstdc++-v3/testsuite/22_locale/money_put/put/char/2.cc index d1c240f..69cfeb6 100644 --- a/libstdc++-v3/testsuite/22_locale/money_put/put/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/money_put/put/char/2.cc @@ -36,9 +36,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -115,6 +115,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_put/put/char/3.cc b/libstdc++-v3/testsuite/22_locale/money_put/put/char/3.cc index 73c84b2..49531ad 100644 --- a/libstdc++-v3/testsuite/22_locale/money_put/put/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/money_put/put/char/3.cc @@ -36,9 +36,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -104,6 +104,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/1.cc index 400ce02..19c04d6 100644 --- a/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/1.cc @@ -36,9 +36,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/2.cc index d99a240..ad5834b 100644 --- a/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/2.cc @@ -36,9 +36,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/3.cc index 8a77783..03c747a 100644 --- a/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/money_put/put/wchar_t/3.cc @@ -36,9 +36,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE@euro"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE@euro"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/moneypunct/members/char/2.cc b/libstdc++-v3/testsuite/22_locale/moneypunct/members/char/2.cc index 7d74101..13d680e 100644 --- a/libstdc++-v3/testsuite/22_locale/moneypunct/members/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/moneypunct/members/char/2.cc @@ -34,7 +34,7 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); // cache the moneypunct facets typedef moneypunct __money_true; @@ -95,6 +95,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/moneypunct/members/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/moneypunct/members/wchar_t/2.cc index 2e258f9..4394d83 100644 --- a/libstdc++-v3/testsuite/22_locale/moneypunct/members/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/moneypunct/members/wchar_t/2.cc @@ -34,7 +34,7 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); // cache the moneypunct facets typedef moneypunct __money_true; diff --git a/libstdc++-v3/testsuite/22_locale/moneypunct_byname/1.cc b/libstdc++-v3/testsuite/22_locale/moneypunct_byname/1.cc index 83fc8f6..70cbf38 100644 --- a/libstdc++-v3/testsuite/22_locale/moneypunct_byname/1.cc +++ b/libstdc++-v3/testsuite/22_locale/moneypunct_byname/1.cc @@ -32,12 +32,12 @@ void test01() bool test = true; string str; + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); + str = loc_de.name(); + locale loc_byname(locale::classic(), new moneypunct_byname("de_DE")); str = loc_byname.name(); - locale loc_de("de_DE"); - str = loc_de.name(); - locale loc_c = locale::classic(); VERIFY( loc_de != loc_byname ); @@ -93,7 +93,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); - + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc index 3723e23..6f972c5 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/char/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -162,7 +162,7 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc index 108fae1..cb446c7 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/char/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -132,7 +132,7 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/char/3.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/char/3.cc index b6c0f12..41867ca 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/char/3.cc @@ -33,9 +33,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -94,7 +94,7 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/char/5.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/char/5.cc index 94da704..0590d49 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/char/5.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/char/5.cc @@ -36,7 +36,7 @@ void test05() istringstream iss; // A locale that expects grouping - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); iss.imbue(loc_de); const num_get& ng = use_facet >(iss.getloc()); @@ -84,7 +84,7 @@ void test05() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test05); + test05(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/char/6.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/char/6.cc index b5e0a21..a6b9417 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/char/6.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/char/6.cc @@ -33,7 +33,7 @@ void test06() double d = 0.0; istringstream iss; - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); iss.imbue(loc_de); const num_get& ng = use_facet >(iss.getloc()); @@ -49,7 +49,7 @@ void test06() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test06); + test06(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc index a30cf97..ef055b3 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc index dc11885..bbf2a98 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/3.cc index d3b1118..65fcf84 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/3.cc @@ -33,9 +33,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/5.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/5.cc index 7eaaa89..8443816 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/5.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/5.cc @@ -36,7 +36,7 @@ void test05() wistringstream iss; // A locale that expects grouping - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); iss.imbue(loc_de); const num_get& ng = use_facet >(iss.getloc()); diff --git a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/6.cc b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/6.cc index 2f4bb1b..57490f3 100644 --- a/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/6.cc +++ b/libstdc++-v3/testsuite/22_locale/num_get/get/wchar_t/6.cc @@ -33,7 +33,7 @@ void test06() double d = 0.0; wistringstream iss; - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); iss.imbue(loc_de); const num_get& ng = use_facet >(iss.getloc()); diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc index 87abef4..b34fce2 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/char/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -169,7 +169,7 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/char/2.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/char/2.cc index a62dfc1..407dbff 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/char/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -105,7 +105,7 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/char/3.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/char/3.cc index 0bc92b2..080a2a4 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/char/3.cc @@ -33,9 +33,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -88,7 +88,7 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/char/5.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/char/5.cc index eb0bd21..055f4c9 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/char/5.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/char/5.cc @@ -33,7 +33,7 @@ void test05() bool test = true; // A locale that expects grouping. - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); const string empty; string result; @@ -63,7 +63,7 @@ void test05() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test05); + test05(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc index 9c5bdc5..28ed5d7 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/2.cc index de08c09..8416c4c 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/3.cc index ae2d0cf..26750ac 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/3.cc @@ -33,9 +33,9 @@ void test03() // basic construction locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/5.cc b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/5.cc index 18ea8ed..dd4799b 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/5.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/put/wchar_t/5.cc @@ -33,7 +33,7 @@ void test05() bool test = true; // A locale that expects grouping. - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); const wstring empty; wstring result; diff --git a/libstdc++-v3/testsuite/22_locale/numpunct/members/char/1.cc b/libstdc++-v3/testsuite/22_locale/numpunct/members/char/1.cc index aba34e2..023c64f 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct/members/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct/members/char/1.cc @@ -31,9 +31,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -60,6 +60,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/numpunct/members/char/2.cc b/libstdc++-v3/testsuite/22_locale/numpunct/members/char/2.cc index ec9512f..b6c8b2d 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct/members/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct/members/char/2.cc @@ -31,9 +31,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); @@ -82,6 +82,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/1.cc index ac4e820..e3426fd 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/1.cc @@ -31,9 +31,9 @@ void test01() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/2.cc index c544b29..9b55ae9 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct/members/wchar_t/2.cc @@ -31,9 +31,9 @@ void test02() // basic construction locale loc_c = locale::classic(); - locale loc_us("en_US"); - locale loc_fr("fr_FR"); - locale loc_de("de_DE"); + locale loc_us = __gnu_cxx_test::try_named_locale("en_US"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_c != loc_de ); VERIFY( loc_us != loc_fr ); VERIFY( loc_us != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/numpunct_byname/1.cc b/libstdc++-v3/testsuite/22_locale/numpunct_byname/1.cc index a6c71dc..96a9691 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct_byname/1.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct_byname/1.cc @@ -30,12 +30,12 @@ void test01() bool test = true; string str; + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); + str = loc_de.name(); + locale loc_byname(locale::classic(), new numpunct_byname("de_DE")); str = loc_byname.name(); - locale loc_de("de_DE"); - str = loc_de.name(); - locale loc_c = locale::classic(); VERIFY( loc_de != loc_byname ); @@ -71,6 +71,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/numpunct_byname/2.cc b/libstdc++-v3/testsuite/22_locale/numpunct_byname/2.cc index f096a8b..6bebbbf 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct_byname/2.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct_byname/2.cc @@ -29,7 +29,7 @@ void test02() bool test = true; - locale loc_it("it_IT"); + locale loc_it = __gnu_cxx_test::try_named_locale("it_IT"); const numpunct& nump_it = use_facet >(loc_it); @@ -40,6 +40,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/date_order/char/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/date_order/char/1.cc index 46958a2..59128a6 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/date_order/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/date_order/char/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -64,6 +64,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/date_order/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/date_order/wchar_t/1.cc index 9baf021..b4a2fcf 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/date_order/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/date_order/wchar_t/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/1.cc index f242c4b..a478279 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/1.cc @@ -34,9 +34,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -107,6 +107,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/2.cc index 274a231..149b952 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_date/char/2.cc @@ -34,9 +34,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -103,6 +103,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/1.cc index 965493d..71a30d1 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/1.cc @@ -34,9 +34,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/2.cc index 1e4d57a..3331239 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_date/wchar_t/2.cc @@ -34,9 +34,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/1.cc index 2fd9b76..6ecbb0a 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/1.cc @@ -37,9 +37,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -121,6 +121,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/2.cc index c98f8d1..6535a66 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/char/2.cc @@ -34,9 +34,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -85,6 +85,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/1.cc index 8ba9d5d..7e82e51 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/1.cc @@ -37,9 +37,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/2.cc index 80fe2df..edab4ba 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_monthname/wchar_t/2.cc @@ -34,9 +34,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/1.cc index 80d996c..8901534 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -122,6 +122,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/2.cc index 1d56827..ddb817f 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_time/char/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -75,6 +75,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/1.cc index 5d64670..a1fe3b3 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/1.cc @@ -33,9 +33,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/2.cc index 5b72938..0151fc6 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_time/wchar_t/2.cc @@ -33,9 +33,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/1.cc index ca89d1e..c530170 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/1.cc @@ -34,9 +34,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -129,6 +129,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/2.cc index 6e9d999..68a7d89 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/char/2.cc @@ -34,9 +34,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -85,6 +85,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/1.cc index a865c2e..0c7d5b4 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/1.cc @@ -34,9 +34,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/2.cc index 299f2ef..af2e3ec 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_weekday/wchar_t/2.cc @@ -34,9 +34,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_year/char/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_year/char/1.cc index aabfd6d..0f408fc 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_year/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_year/char/1.cc @@ -34,9 +34,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -118,6 +118,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_get/get_year/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_get/get_year/wchar_t/1.cc index c117311..e5c726a 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/get_year/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/get_year/wchar_t/1.cc @@ -34,9 +34,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/1.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/1.cc index f54a8c9..d3acb9b 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/1.cc @@ -40,9 +40,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -85,6 +85,6 @@ void test01() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test01); + test01(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/2.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/2.cc index 665036b..4656efc 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/2.cc @@ -40,9 +40,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -80,6 +80,6 @@ void test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/3.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/3.cc index 3399669..3b768db 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/3.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/3.cc @@ -40,9 +40,9 @@ void test03() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -80,6 +80,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/4.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/4.cc index afb45ee..d07fad6 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/4.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/4.cc @@ -40,9 +40,9 @@ void test04() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -79,6 +79,6 @@ void test04() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test04); + test04(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/5.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/5.cc index b7b0055..e1355b8 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/5.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/5.cc @@ -41,9 +41,9 @@ void test05() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -75,6 +75,6 @@ void test05() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test05); + test05(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/6.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/6.cc index 9287571..5634d9f 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/6.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/6.cc @@ -41,9 +41,9 @@ void test06() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -73,6 +73,6 @@ void test06() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test06); + test06(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/7.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/7.cc index 00cefcf..91a5e9b 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/7.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/7.cc @@ -42,9 +42,9 @@ void test07() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -74,6 +74,6 @@ void test07() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test07); + test07(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/char/8.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/char/8.cc index 10afde5..7409ff9 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/char/8.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/char/8.cc @@ -41,9 +41,9 @@ void test08() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); @@ -72,6 +72,6 @@ void test08() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test08); + test08(); return 0; } diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc index 914b187..874b628 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/1.cc @@ -40,9 +40,9 @@ void test01() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/2.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/2.cc index bddb23f..b41e6a7 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/2.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/2.cc @@ -40,9 +40,9 @@ void test02() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/3.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/3.cc index 566a3a5..d3cf9dd 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/3.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/3.cc @@ -40,9 +40,9 @@ void test03() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/4.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/4.cc index 88d3b04..db04bcc 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/4.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/4.cc @@ -40,9 +40,9 @@ void test04() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc index ac53243..9268127 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/5.cc @@ -41,9 +41,9 @@ void test05() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/6.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/6.cc index 0f58555..90f7614 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/6.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/6.cc @@ -41,9 +41,9 @@ void test06() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/7.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/7.cc index 44a86ac..c631478 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/7.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/7.cc @@ -41,9 +41,9 @@ void test07() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/8.cc b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/8.cc index 900dc13..a7edf18 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/8.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/put/wchar_t/8.cc @@ -41,9 +41,9 @@ void test08() // basic construction and sanity checks. locale loc_c = locale::classic(); - locale loc_hk("en_HK"); - locale loc_fr("fr_FR@euro"); - locale loc_de("de_DE"); + locale loc_hk = __gnu_cxx_test::try_named_locale("en_HK"); + locale loc_fr = __gnu_cxx_test::try_named_locale("fr_FR@euro"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); VERIFY( loc_hk != loc_c ); VERIFY( loc_hk != loc_fr ); VERIFY( loc_hk != loc_de ); diff --git a/libstdc++-v3/testsuite/27_io/basic_filebuf/imbue/char/9322.cc b/libstdc++-v3/testsuite/27_io/basic_filebuf/imbue/char/9322.cc index e584f46..5a43a2a 100644 --- a/libstdc++-v3/testsuite/27_io/basic_filebuf/imbue/char/9322.cc +++ b/libstdc++-v3/testsuite/27_io/basic_filebuf/imbue/char/9322.cc @@ -34,10 +34,10 @@ void test07() std::filebuf ob; VERIFY( ob.getloc() == loc ); - locale::global(locale("en_US")); + locale::global(__gnu_cxx_test::try_named_locale("en_US")); VERIFY( ob.getloc() == loc ); - locale loc_de ("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); locale ret = ob.pubimbue(loc_de); VERIFY( ob.getloc() == loc_de ); VERIFY( ret == loc ); @@ -48,6 +48,6 @@ void test07() main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test07); + test07(); return 0; } diff --git a/libstdc++-v3/testsuite/27_io/basic_ios/copyfmt/char/2.cc b/libstdc++-v3/testsuite/27_io/basic_ios/copyfmt/char/2.cc index 03d4515..6daa4e0 100644 --- a/libstdc++-v3/testsuite/27_io/basic_ios/copyfmt/char/2.cc +++ b/libstdc++-v3/testsuite/27_io/basic_ios/copyfmt/char/2.cc @@ -43,7 +43,7 @@ void test03() typedef std::ios_base::fmtflags fmtflags; typedef std::ios_base::iostate iostate; locale loc_c = locale::classic(); - locale loc_de("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); std::ios ios_01(NULL); std::ios ios_02(NULL); ios_01.imbue(loc_c); @@ -68,6 +68,6 @@ void test03() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/2.cc b/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/2.cc index ed4979f..9218092 100644 --- a/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/2.cc +++ b/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_arithmetic/char/2.cc @@ -43,7 +43,7 @@ test02() os2.setf(ios::fixed); // Check it can be done in a locale with grouping on. - locale loc2("de_DE"); + locale loc2 = __gnu_cxx_test::try_named_locale("de_DE"); os2.imbue(loc2); os2 << fixed << setprecision(3) << val2 << endl; os2 << endl; @@ -53,6 +53,6 @@ test02() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test02); + test02(); return 0; } diff --git a/libstdc++-v3/testsuite/27_io/basic_streambuf/imbue/char/9322.cc b/libstdc++-v3/testsuite/27_io/basic_streambuf/imbue/char/9322.cc index 3b8da10..fee8266 100644 --- a/libstdc++-v3/testsuite/27_io/basic_streambuf/imbue/char/9322.cc +++ b/libstdc++-v3/testsuite/27_io/basic_streambuf/imbue/char/9322.cc @@ -53,10 +53,10 @@ void test08() testbuf ob; VERIFY( ob.getloc() == loc ); - locale::global(locale("en_US")); + locale::global(__gnu_cxx_test::try_named_locale("en_US")); VERIFY( ob.getloc() == loc ); - locale loc_de ("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); locale ret = ob.pubimbue(loc_de); VERIFY( ob.getloc() == loc_de ); VERIFY( ret == loc ); @@ -67,6 +67,6 @@ void test08() int main() { - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test08); + test08(); return 0; } diff --git a/libstdc++-v3/testsuite/27_io/basic_stringbuf/imbue/char/9322.cc b/libstdc++-v3/testsuite/27_io/basic_stringbuf/imbue/char/9322.cc index 3da38fb..7006dda 100644 --- a/libstdc++-v3/testsuite/27_io/basic_stringbuf/imbue/char/9322.cc +++ b/libstdc++-v3/testsuite/27_io/basic_stringbuf/imbue/char/9322.cc @@ -33,10 +33,10 @@ void test03() std::stringbuf ob; VERIFY( ob.getloc() == loc ); - locale::global(locale("en_US")); + locale::global(__gnu_cxx_test::try_named_locale("en_US")); VERIFY( ob.getloc() == loc ); - locale loc_de ("de_DE"); + locale loc_de = __gnu_cxx_test::try_named_locale("de_DE"); locale ret = ob.pubimbue(loc_de); VERIFY( ob.getloc() == loc_de ); VERIFY( ret == loc ); @@ -48,6 +48,6 @@ void test03() int main() { using namespace std; - __gnu_cxx_test::run_test_wrapped_generic_locale_exception_catcher(test03); + test03(); return 0; } diff --git a/libstdc++-v3/testsuite/testsuite_hooks.cc b/libstdc++-v3/testsuite/testsuite_hooks.cc index d51a3d3..988ef03 100644 --- a/libstdc++-v3/testsuite/testsuite_hooks.cc +++ b/libstdc++-v3/testsuite/testsuite_hooks.cc @@ -148,20 +148,8 @@ namespace __gnu_cxx_test bool test = true; // Set the global locale. - try - { - locale loc_name(name); - locale orig = locale::global(loc_name); - } - catch (std::runtime_error& ex) - { - if (std::strstr (ex.what(), "unhandled name in generic implementation")) - return; - else if (std::strstr (ex.what(), "unknown name")) - return; - else - throw; - } + locale loc_name = try_named_locale(name); + locale orig = locale::global(loc_name); const char* res = setlocale(LC_ALL, name); if (res != NULL) @@ -185,20 +173,9 @@ namespace __gnu_cxx_test #ifdef _GLIBCPP_HAVE_SETENV // Set the global locale. - try - { - locale loc_name(name); - locale orig = locale::global(loc_name); - } - catch (std::runtime_error& ex) - { - if (std::strstr (ex.what(), "unhandled name in generic implementation")) - return; - else if (std::strstr (ex.what(), "unknown name")) - return; - else - throw; - } + locale loc_name = try_named_locale(name); + locale orig = locale::global(loc_name); + // Set environment variable env to value in name. const char* oldENV = getenv(env); if (!setenv(env, name, 1)) @@ -212,19 +189,21 @@ namespace __gnu_cxx_test #endif } - void - run_test_wrapped_generic_locale_exception_catcher(const test_func f) + std::locale + try_named_locale(const char* name) { try { - f(); + return std::locale(name); } catch (std::runtime_error& ex) { - if (std::strstr (ex.what(), "unhandled name in generic implementation")) - return; - else if (std::strstr (ex.what(), "unknown name")) - return; + // Thrown by generic implemenation. + if (std::strstr(ex.what(), "unhandled name in generic implementation")) + exit(0); + // Thrown by gnu implemenation. + else if (std::strstr(ex.what(), "unknown name")) + exit(0); else throw; } diff --git a/libstdc++-v3/testsuite/testsuite_hooks.h b/libstdc++-v3/testsuite/testsuite_hooks.h index da397e3..0c3aae6 100644 --- a/libstdc++-v3/testsuite/testsuite_hooks.h +++ b/libstdc++-v3/testsuite/testsuite_hooks.h @@ -68,6 +68,7 @@ # define VERIFY(fn) test &= (fn) #endif #include +#include namespace __gnu_cxx_test { @@ -105,9 +106,9 @@ namespace __gnu_cxx_test void run_tests_wrapped_env(const char*, const char*, const func_callback&); - // Run select unit test inside exception catcher for non-C named locale - void - run_test_wrapped_generic_locale_exception_catcher(const test_func); + // Try to create a locale with the given name. If it fails, bail. + std::locale + try_named_locale(const char* name); // Test data types. struct pod_char -- 2.7.4