]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/test/cintltst/uenumtst.c
ICU-66108.tar.gz
[apple/icu.git] / icuSources / test / cintltst / uenumtst.c
index 39e2494975ff1c83538eb89bf4111a8ce6d73821..8ce05e9b9cb7599273ad19754c54ae50dc6e1823 100644 (file)
@@ -59,11 +59,13 @@ chArrayClose(UEnumeration *en) {
 
 static int32_t U_CALLCONV
 chArrayCount(UEnumeration *en, UErrorCode *status) {
+    (void)status; // suppress compiler warnings about unused variable
     return cont->maxIndex;
 }
 
 static const UChar* U_CALLCONV 
 chArrayUNext(UEnumeration *en, int32_t *resultLength, UErrorCode *status) {
+    (void)status; // suppress compiler warnings about unused variable
     if(cont->currIndex >= cont->maxIndex) {
         return NULL;
     }
@@ -81,6 +83,7 @@ chArrayUNext(UEnumeration *en, int32_t *resultLength, UErrorCode *status) {
 
 static const char* U_CALLCONV
 chArrayNext(UEnumeration *en, int32_t *resultLength, UErrorCode *status) {
+    (void)status; // suppress compiler warnings about unused variable
     if(cont->currIndex >= cont->maxIndex) {
         return NULL;
     }
@@ -93,6 +96,7 @@ chArrayNext(UEnumeration *en, int32_t *resultLength, UErrorCode *status) {
 
 static void U_CALLCONV
 chArrayReset(UEnumeration *en, UErrorCode *status) {
+    (void)status; // suppress compiler warnings about unused variable
     cont->currIndex = 0;
 }
 
@@ -160,11 +164,13 @@ uchArrayClose(UEnumeration *en) {
 
 static int32_t U_CALLCONV
 uchArrayCount(UEnumeration *en, UErrorCode *status) {
+    (void)status; // suppress compiler warnings about unused variable
     return ucont->maxIndex;
 }
 
 static const UChar* U_CALLCONV
 uchArrayUNext(UEnumeration *en, int32_t *resultLength, UErrorCode *status) {
+    (void)status; // suppress compiler warnings about unused variable
     if(ucont->currIndex >= ucont->maxIndex) {
         return NULL;
     }
@@ -177,6 +183,7 @@ uchArrayUNext(UEnumeration *en, int32_t *resultLength, UErrorCode *status) {
 
 static void U_CALLCONV
 uchArrayReset(UEnumeration *en, UErrorCode *status) {
+    (void)status; // suppress compiler warnings about unused variable
     ucont->currIndex = 0;
 }
 
@@ -343,7 +350,7 @@ static void verifyEnumeration(int line, UEnumeration *u, const char * const * co
         log_verbose("%s:%d: OK: string #%d got '%s'\n", __FILE__, line, i, c);
       }
       
-      if(len!=strlen(compareToChar[i])) {
+      if(len!=(int32_t)strlen(compareToChar[i])) {
         log_err("%s:%d: FAIL: string #%d expected len %d got %d\n", __FILE__, line, i, strlen(compareToChar[i]), len);
       } else {
         log_verbose("%s:%d: OK: string #%d got len %d\n", __FILE__, line, i, len);
@@ -380,7 +387,7 @@ static void verifyEnumeration(int line, UEnumeration *u, const char * const * co
         log_verbose("%s:%d: OK: ustring #%d got '%s'\n", __FILE__, line, i, compareToChar[i]);
       }
       
-      if(len!=strlen(compareToChar[i])) {
+      if(len!=(int32_t)strlen(compareToChar[i])) {
         log_err("%s:%d: FAIL: ustring #%d expected len %d got %d\n", __FILE__, line, i, strlen(compareToChar[i]), len);
       } else {
         log_verbose("%s:%d: OK: ustring #%d got len %d\n", __FILE__, line, i, len);