]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/test/iotest/filetst.c
ICU-66108.tar.gz
[apple/icu.git] / icuSources / test / iotest / filetst.c
index 1c667e174e128e31f19220cf7a2154b76d4a068d..e074b9020d88593fbd0ea04163e4a7221b8643ef 100644 (file)
@@ -1120,7 +1120,7 @@ static void TestFilePrintCompatibility(void) {
 }
 #endif
 
-#define TestFPrintFormat(uFormat, uValue, cFormat, cValue) \
+#define TestFPrintFormat(uFormat, uValue, cFormat, cValue) UPRV_BLOCK_MACRO_BEGIN { \
     myFile = u_fopen(STANDARD_TEST_FILE, "w", STANDARD_TEST_LOCALE, NULL);\
     if (myFile == NULL) {\
         log_err("Can't write test file for %s.\n", uFormat);\
@@ -1146,6 +1146,7 @@ static void TestFilePrintCompatibility(void) {
     if (buffer[uNumPrinted+1] != '*') {\
         log_err("%" uFormat " too much stored\n");\
     }\
+} UPRV_BLOCK_MACRO_END
 
 #if !UCONFIG_NO_FORMATTING
 static void TestFprintfFormat(void) {
@@ -1381,6 +1382,7 @@ static void TestFScanset(void) {
 #endif
 #if !UCONFIG_NO_FORMATTING
 static void TestBadFScanfFormat(const char *format, const UChar *uValue, const char *cValue) {
+    (void)cValue; // suppress compiler warnings about unused variable
     UFILE *myFile;
     UChar uBuffer[256];
     int32_t uNumScanned;