X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/57a6839dcb3bba09e8228b822b290604668416fe..f3c0d7a59d99c2a94c6b8822291f0e42be3773c9:/icuSources/test/intltest/restsnew.cpp diff --git a/icuSources/test/intltest/restsnew.cpp b/icuSources/test/intltest/restsnew.cpp index e6240c09..5483cddb 100644 --- a/icuSources/test/intltest/restsnew.cpp +++ b/icuSources/test/intltest/restsnew.cpp @@ -1,10 +1,13 @@ +// © 2016 and later: Unicode, Inc. and others. +// License & terms of use: http://www.unicode.org/copyright.html /******************************************************************** - * Copyright (c) 1997-2014, International Business Machines + * Copyright (c) 1997-2016, International Business Machines * Corporation and others. All Rights Reserved. ********************************************************************/ #include "unicode/utypes.h" +#include "cmemory.h" #include "cstring.h" #include "unicode/unistr.h" #include "unicode/resbund.h" @@ -106,7 +109,7 @@ param[] = { "ne", 0, U_USING_DEFAULT_WARNING, e_Root, { TRUE, FALSE, FALSE }, { TRUE, FALSE, FALSE } } }; -static int32_t bundles_count = sizeof(param) / sizeof(param[0]); +static int32_t bundles_count = UPRV_LENGTHOF(param); //*************************************************************************************** @@ -170,7 +173,7 @@ NewResourceBundleTest::~NewResourceBundleTest() { if (param[5].locale) { int idx; - for (idx = 0; idx < (int)(sizeof(param)/sizeof(param[0])); idx++) { + for (idx = 0; idx < UPRV_LENGTHOF(param); idx++) { delete param[idx].locale; param[idx].locale = NULL; } @@ -330,7 +333,7 @@ NewResourceBundleTest::TestIteration() UnicodeString action; - for(i=0; i