X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/729e4ab9bc6618bc3d8a898e575df7f4019e29ca..b801cf366c7671a99bdcef84d1e9c0ec64b36723:/icuSources/test/cintltst/utmstest.c diff --git a/icuSources/test/cintltst/utmstest.c b/icuSources/test/cintltst/utmstest.c index bc9f614f..156c8e8c 100644 --- a/icuSources/test/cintltst/utmstest.c +++ b/icuSources/test/cintltst/utmstest.c @@ -1,6 +1,6 @@ /* **************************************************************************** - * Copyright (c) 1997-2010, International Business Machines Corporation and * + * Copyright (c) 1997-2014, International Business Machines Corporation and * * others. All Rights Reserved. * **************************************************************************** */ @@ -13,12 +13,11 @@ #include "unicode/ucal.h" #include "cintltst.h" +#include "cmemory.h" #include #include -#define LENGTHOF(array) (int32_t)(sizeof(array)/sizeof((array)[0])) - #define LOOP_COUNT 10000 static void TestAPI(void); @@ -198,6 +197,7 @@ static void TestFromInt64(void) UErrorCode status = U_ZERO_ERROR; result = utmscale_fromInt64(0, -1, &status); + (void)result; /* Suppress set but not used warning. */ if (status != U_ILLEGAL_ARGUMENT_ERROR) { log_err("utmscale_fromInt64(0, -1, status) did not set status to U_ILLEGAL_ARGUMENT_ERROR.\n"); } @@ -258,6 +258,7 @@ static void TestToInt64(void) UErrorCode status = U_ZERO_ERROR; result = utmscale_toInt64(0, -1, &status); + (void)result; /* suppress set but not used warning. */ if (status != U_ILLEGAL_ARGUMENT_ERROR) { log_err("utmscale_toInt64(0, -1, &status) did not generate U_ILLEGAL_ARGUMENT_ERROR.\n"); } @@ -459,7 +460,7 @@ TestDotNet() { ucal_close(cal); return; } - for(i = 0; i < LENGTHOF(dotNetDateTimeTicks); ++i) { + for(i = 0; i < UPRV_LENGTHOF(dotNetDateTimeTicks); ++i) { /* Test conversion from .Net/Universal time to ICU time. */ dt = dotNetDateTimeTicks + i; millis = utmscale_toInt64(dt->ticks, UDTS_ICU4C_TIME, &errorCode);