]> granicus.if.org Git - icu/commitdiff
ICU-10977 remove stray #if DEBUG from a few more files
authorSteven R. Loomis <srl@icu-project.org>
Wed, 25 Jun 2014 21:59:55 +0000 (21:59 +0000)
committerSteven R. Loomis <srl@icu-project.org>
Wed, 25 Jun 2014 21:59:55 +0000 (21:59 +0000)
X-SVN-Rev: 35948

icu4c/source/i18n/rbnf.cpp
icu4c/source/layout/KernTable.cpp
icu4c/source/test/intltest/nptrans.cpp

index 894e6b6d2a38e554f5ea6a752eca71d377047abc..4bd7c2ccd5bd81f77bfd6b25451e75eabefb2c96 100644 (file)
@@ -32,9 +32,9 @@
 #include "uresimp.h"
 
 // debugging
-// #define DEBUG
+// #define RBNF_DEBUG
 
-#ifdef DEBUG
+#ifdef RBNF_DEBUG
 #include "stdio.h"
 #endif
 
@@ -327,7 +327,7 @@ private:
     UChar*  nextString(void);
 };
 
-#ifdef DEBUG
+#ifdef RBNF_DEBUG
 #define ERROR(msg) parseError(msg); return NULL;
 #define EXPLANATION_ARG explanationArg
 #else
@@ -556,7 +556,7 @@ void LocDataParser::parseError(const char* EXPLANATION_ARG)
     pe.postContext[limit-p] = 0;
     pe.offset = (int32_t)(p - data);
     
-#ifdef DEBUG
+#ifdef RBNF_DEBUG
     fprintf(stderr, "%s at or near character %ld: ", EXPLANATION_ARG, p-data);
 
     UnicodeString msg;
index 866e2cea7b6b02ea70185b69fb948b63871ff446..700053248d0f6b814bc2681dfd4e2bd4f438026c 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * @(#)KernTable.cpp   1.1 04/10/13
  *
- * (C) Copyright IBM Corp. 2004-2013 - All Rights Reserved
+ * (C) Copyright IBM Corp. 2004-2014 - All Rights Reserved
  *
  */
 
@@ -14,7 +14,7 @@
 
 #include <stdio.h>
 
-#define DEBUG 0
+#define KERNTABLE_DEBUG 0
 
 U_NAMESPACE_BEGIN
 
@@ -78,14 +78,14 @@ KernTable::KernTable(const LETableReference& base, LEErrorCode &success)
   : pairs(), fTable(base)
 {
   if(LE_FAILURE(success) || fTable.isEmpty()) {
-#if DEBUG
+#if KERNTABLE_DEBUG
     fprintf(stderr, "no kern data\n");
 #endif
     return;
   }
   LEReferenceTo<KernTableHeader> header(fTable, success);
 
-#if DEBUG
+#if KERNTABLE_DEBUG
   // dump first 32 bytes of header
   for (int i = 0; i < 64; ++i) {
     fprintf(stderr, "%0.2x ", ((const char*)header.getAlias())[i]&0xff);
@@ -138,7 +138,7 @@ KernTable::KernTable(const LETableReference& base, LEErrorCode &success)
         fprintf(stderr, "  searchRange: %d entrySelector: %d rangeShift: %d\n", searchRange, entrySelector, rangeShift);
         fprintf(stderr, "[[ ignored font table entries: range %d selector %d shift %d ]]\n", SWAPW(table->searchRange), SWAPW(table->entrySelector), SWAPW(table->rangeShift));
 #endif
-#if DEBUG
+#if KERNTABLE_DEBUG
         fprintf(stderr, "coverage: %0.4x nPairs: %d pairs 0x%x\n", coverage, nPairs, pairs);
         fprintf(stderr, "  searchRange: %d entrySelector: %d rangeShift: %d\n", searchRange, entrySelector, rangeShift);
 
@@ -215,7 +215,7 @@ void KernTable::process(LEGlyphStorage& storage, LEErrorCode &success)
         p = tp;
       }
 
-#if DEBUG
+#if KERNTABLE_DEBUG
       fprintf(stderr, "binary search for %0.8x\n", key);
 #endif
 
@@ -227,13 +227,13 @@ void KernTable::process(LEGlyphStorage& storage, LEErrorCode &success)
         tp = tpRef.getAlias();
         le_uint32 tkey = SWAP_KEY(tp);
         if(LE_FAILURE(success)) break;
-#if DEBUG
+#if KERNTABLE_DEBUG
         fprintf(stdout, "   %.3d (%0.8x)\n", ((char*)tp - (char*)pairs)/KERN_PAIRINFO_SIZE, tkey);
 #endif
         if (tkey <= key && LE_SUCCESS(success)) {
           if (tkey == key) {
             le_int16 value = SWAPW(tp->value);
-#if DEBUG
+#if KERNTABLE_DEBUG
             fprintf(stdout, "binary found kerning pair %x:%x at %d, value: 0x%x (%g)\n",
               storage[i-1], storage[i], i, value & 0xffff, font->xUnitsToPoints(value));
             fflush(stdout);
index a4a591ba2a26fd72d3d4c8c4309973b7b20a083d..27345adf62e79c298072be76ac8158742322dc60 100644 (file)
@@ -1,7 +1,7 @@
 /*
  *******************************************************************************
  *
- *   Copyright (C) 2003-2010, International Business Machines
+ *   Copyright (C) 2003-2014, International Business Machines
  *   Corporation and others.  All Rights Reserved.
  *
  *******************************************************************************
@@ -27,7 +27,7 @@
 #include "ustr_imp.h"
 #include "intltest.h"
 
-#ifdef DEBUG 
+#ifdef NPTRANS_DEBUG 
 #include <stdio.h>
 #endif
 
@@ -84,14 +84,14 @@ NamePrepTransform::NamePrepTransform(UParseError& parseError, UErrorCode& status
         pattern =  ures_getStringByKey(bundle,"ProhibitedSet",&patternLen, &status);
         UnicodeString test(pattern,patternLen);
         prohibited.applyPattern(test,status);
-#ifdef DEBUG
+#ifdef NPTRANS_DEBUG
         if(U_FAILURE(status)){
             printf("Construction of Unicode set failed\n");
         }
 
         if(U_SUCCESS(status)){
             if(prohibited.contains((UChar) 0x644)){
-                printf("The string contains 0x644 ... damn !!\n");
+                printf("The string contains 0x644 ... !!\n");
             }
             UnicodeString temp;
             prohibited.toPattern(temp,TRUE);