]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/test/cintltst/trietest.c
ICU-57131.0.1.tar.gz
[apple/icu.git] / icuSources / test / cintltst / trietest.c
index ac595b675764516d11649b90ccc1377cd120cc82..69999f0bf68152c7f12935a1d83adbcd2e603693 100644 (file)
@@ -1,7 +1,7 @@
 /*
 ******************************************************************************
 *
-*   Copyright (C) 2001-2011, International Business Machines
+*   Copyright (C) 2001-2016, International Business Machines
 *   Corporation and others.  All Rights Reserved.
 *
 ******************************************************************************
@@ -32,8 +32,6 @@
 #define u_errorName(errorCode) "some error code"
 #endif
 
-#define ARRAY_LENGTH(array) (sizeof(array)/sizeof(array[0]))
-
 /* Values for setting possibly overlapping, out-of-order ranges of values */
 typedef struct SetRange {
     UChar32 start, limit;
@@ -801,14 +799,14 @@ checkRanges3[]={
 static void
 TrieTest(void) {
     testTrieRanges4("set1",
-        setRanges1, ARRAY_LENGTH(setRanges1),
-        checkRanges1, ARRAY_LENGTH(checkRanges1));
+        setRanges1, UPRV_LENGTHOF(setRanges1),
+        checkRanges1, UPRV_LENGTHOF(checkRanges1));
     testTrieRanges4("set2-overlap",
-        setRanges2, ARRAY_LENGTH(setRanges2),
-        checkRanges2, ARRAY_LENGTH(checkRanges2));
+        setRanges2, UPRV_LENGTHOF(setRanges2),
+        checkRanges2, UPRV_LENGTHOF(checkRanges2));
     testTrieRanges4("set3-initial-9",
-        setRanges3, ARRAY_LENGTH(setRanges3),
-        checkRanges3, ARRAY_LENGTH(checkRanges3));
+        setRanges3, UPRV_LENGTHOF(setRanges3),
+        checkRanges3, UPRV_LENGTHOF(checkRanges3));
 }
 
 /* test utrie_unserializeDummy() -------------------------------------------- */