You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stdcxx.apache.org by fa...@apache.org on 2007/11/19 16:18:52 UTC
svn commit: r596324 -
/incubator/stdcxx/branches/4.2.x/tests/localization/22.locale.ctype.is.cpp
Author: faridz
Date: Mon Nov 19 07:18:51 2007
New Revision: 596324
URL: http://svn.apache.org/viewvc?rev=596324&view=rev
Log:
2007-11-19 Farid Zaripov <fa...@epam.com>
* 22.locale.ctype.is (run_test<>): The compile time
checks moved to test_libstd(); The function run_test<>()
removed; The test_libstd() and test_libc() functions are
invoked from non-template run_test() to invoke them in
the following order: test_libc<char>(), test_libc<wchar_t>(),
test_libstd<char>(), test_libstd<wchar_t>().
Modified:
incubator/stdcxx/branches/4.2.x/tests/localization/22.locale.ctype.is.cpp
Modified: incubator/stdcxx/branches/4.2.x/tests/localization/22.locale.ctype.is.cpp
URL: http://svn.apache.org/viewvc/incubator/stdcxx/branches/4.2.x/tests/localization/22.locale.ctype.is.cpp?rev=596324&r1=596323&r2=596324&view=diff
==============================================================================
--- incubator/stdcxx/branches/4.2.x/tests/localization/22.locale.ctype.is.cpp (original)
+++ incubator/stdcxx/branches/4.2.x/tests/localization/22.locale.ctype.is.cpp Mon Nov 19 07:18:51 2007
@@ -840,6 +840,12 @@
template <class charT>
void test_libstd (charT, const char *cname)
{
+ if (0) {
+ // do a compile time only test on use_facet and has_facet
+ _STD_HAS_FACET (std::ctype_byname<charT>, std::locale ());
+ _STD_USE_FACET (std::ctype_byname<charT>, std::locale ());
+ }
+
const char cmap_1[] = {
"<code_set_name> \"ANSI_X3.4-1968\"\n"
"<mb_cur_max> 1\n"
@@ -1025,26 +1031,20 @@
/**************************************************************************/
-template <class charT>
-void run_test (charT, const char *cname)
+static int
+run_test (int, char**)
{
- if (0) {
- // do a compile time only test on use_facet and has_facet
- _STD_HAS_FACET (std::ctype_byname<charT>, std::locale ());
- _STD_USE_FACET (std::ctype_byname<charT>, std::locale ());
- }
+ test_libc (char (), "char");
- test_libstd (charT (), cname);
- test_libc (charT (), cname);
-}
+#ifndef _RWSTD_NO_WCHAR_T
+ test_libc (wchar_t (), "wchar_t");
+#endif // _RWSTD_NO_WCHAR_T
-/**************************************************************************/
+ test_libstd (char (), "char");
-static int
-run_test (int, char**)
-{
- run_test (char (), "char");
- run_test (wchar_t (), "wchar_t");
+#ifndef _RWSTD_NO_WCHAR_T
+ test_libstd (wchar_t (), "wchar_t");
+#endif // _RWSTD_NO_WCHAR_T
return 0;
}