X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/374ca955a76ecab1204ca8bfa63ff9238d998416..2be6500137966bba13903b24204a44804f9e133a:/icuSources/test/intltest/g7coll.cpp diff --git a/icuSources/test/intltest/g7coll.cpp b/icuSources/test/intltest/g7coll.cpp index 1cfa3854..e49a6443 100644 --- a/icuSources/test/intltest/g7coll.cpp +++ b/icuSources/test/intltest/g7coll.cpp @@ -1,6 +1,6 @@ /******************************************************************** * COPYRIGHT: - * Copyright (c) 1997-2003, International Business Machines Corporation and + * Copyright (c) 1997-2010, International Business Machines Corporation and * others. All Rights Reserved. ********************************************************************/ @@ -16,7 +16,7 @@ #include "sfwdchit.h" -const UChar G7CollationTest::testCases[][G7CollationTest::MAX_TOKEN_LEN] = { +static const UChar testCases[][G7CollationTest::MAX_TOKEN_LEN] = { { 0x0062 /*'b'*/, 0x006c /*'l'*/, 0x0061 /*'a'*/, 0x0062 /*'c'*/, 0x006b /*'k'*/, 0x0062 /*'b'*/, 0x0069 /*'i'*/, 0x0072 /*'r'*/, 0x0064 /*'d'*/, 0x0073 /*'s'*/, 0x0000}, /* 9 */ { 0x0050 /*'P'*/, 0x0061 /*'a'*/, 0x0074/*'t'*/, 0x0000}, /* 1 */ @@ -56,11 +56,11 @@ const UChar G7CollationTest::testCases[][G7CollationTest::MAX_TOKEN_LEN] = { { 0x007a /*'z'*/, 0x0065 /*'e'*/, 0x0062 /*'b'*/, 0x0072 /*'r'*/, 0x0061 /*'a'*/, 0x0000} /* 29 */ }; -const int32_t G7CollationTest::results[G7CollationTest::TESTLOCALES][G7CollationTest::TOTALTESTSET] = { +static const int32_t results[G7CollationTest::TESTLOCALES][G7CollationTest::TOTALTESTSET] = { { 12, 13, 9, 0, 14, 1, 11, 2, 3, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* en_US */ { 12, 13, 9, 0, 14, 1, 11, 2, 3, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* en_GB */ { 12, 13, 9, 0, 14, 1, 11, 2, 3, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* en_CA */ - { 12, 13, 9, 0, 14, 1, 11, 3, 2, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* fr_FR */ + { 12, 13, 9, 0, 14, 1, 11, 2, 3, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* fr_FR */ { 12, 13, 9, 0, 14, 1, 11, 3, 2, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* fr_CA */ { 12, 13, 9, 0, 14, 1, 11, 2, 3, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* de_DE */ { 12, 13, 9, 0, 14, 1, 11, 2, 3, 4, 5, 6, 8, 10, 7, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31 }, /* it_IT */ @@ -102,7 +102,7 @@ void G7CollationTest::TestG7Locales(/* char* par */) myCollation = Collator::createInstance(locales[i], status); if(U_FAILURE(status)) { delete myCollation; - errln("Couldn't instantiate collator. Error: %s", u_errorName(status)); + errcheckln(status, "Couldn't instantiate collator. Error: %s", u_errorName(status)); return; } myCollation->setStrength(Collator::QUATERNARY); @@ -162,7 +162,7 @@ void G7CollationTest::TestDemo1(/* char* par */) Collator *col = Collator::createInstance("en_US", status); if(U_FAILURE(status)) { delete col; - errln("Couldn't instantiate collator. Error: %s", u_errorName(status)); + errcheckln(status, "Couldn't instantiate collator. Error: %s", u_errorName(status)); return; } const UnicodeString baseRules = ((RuleBasedCollator*)col)->getRules(); @@ -196,7 +196,7 @@ void G7CollationTest::TestDemo2(/* char* par */) Collator *col = Collator::createInstance("en_US", status); if(U_FAILURE(status)) { delete col; - errln("Couldn't instantiate collator. Error: %s", u_errorName(status)); + errcheckln(status, "Couldn't instantiate collator. Error: %s", u_errorName(status)); return; } const UnicodeString baseRules = ((RuleBasedCollator*)col)->getRules(); @@ -229,7 +229,7 @@ void G7CollationTest::TestDemo3(/* char* par */) UErrorCode status = U_ZERO_ERROR; Collator *col = Collator::createInstance("en_US", status); if(U_FAILURE(status)) { - errln("Couldn't instantiate collator. Error: %s", u_errorName(status)); + errcheckln(status, "Couldn't instantiate collator. Error: %s", u_errorName(status)); delete col; return; } @@ -264,7 +264,7 @@ void G7CollationTest::TestDemo4(/* char* par */) Collator *col = Collator::createInstance("en_US", status); if(U_FAILURE(status)) { delete col; - errln("Couldn't instantiate collator. Error: %s", u_errorName(status)); + errcheckln(status, "Couldn't instantiate collator. Error: %s", u_errorName(status)); return; }