| OLD | NEW |
| 1 /*********************************************************************** | 1 /*********************************************************************** |
| 2 * COPYRIGHT: | 2 * COPYRIGHT: |
| 3 * Copyright (c) 1997-2010, International Business Machines Corporation | 3 * Copyright (c) 1997-2010, International Business Machines Corporation |
| 4 * and others. All Rights Reserved. | 4 * and others. All Rights Reserved. |
| 5 ***********************************************************************/ | 5 ***********************************************************************/ |
| 6 | 6 |
| 7 #include "unicode/utypes.h" | 7 #include "unicode/utypes.h" |
| 8 | 8 |
| 9 #if !UCONFIG_NO_FORMATTING | 9 #if !UCONFIG_NO_FORMATTING |
| 10 | 10 |
| (...skipping 935 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 946 {"GMT-01010101", kUnparseable}, | 946 {"GMT-01010101", kUnparseable}, |
| 947 {0, 0} | 947 {0, 0} |
| 948 }; | 948 }; |
| 949 | 949 |
| 950 for (i=0; kData[i].customId != 0; i++) { | 950 for (i=0; kData[i].customId != 0; i++) { |
| 951 UnicodeString id(kData[i].customId); | 951 UnicodeString id(kData[i].customId); |
| 952 int32_t exp = kData[i].expectedOffset; | 952 int32_t exp = kData[i].expectedOffset; |
| 953 TimeZone *zone = TimeZone::createTimeZone(id); | 953 TimeZone *zone = TimeZone::createTimeZone(id); |
| 954 UnicodeString itsID, temp; | 954 UnicodeString itsID, temp; |
| 955 | 955 |
| 956 if (dynamic_cast<OlsonTimeZone *>(zone) != NULL) { | 956 if (CR_DYNAMIC_CAST<OlsonTimeZone *>(zone) != NULL) { |
| 957 logln(id + " -> Olson time zone"); | 957 logln(id + " -> Olson time zone"); |
| 958 } else { | 958 } else { |
| 959 zone->getID(itsID); | 959 zone->getID(itsID); |
| 960 int32_t ioffset = zone->getRawOffset()/1000; | 960 int32_t ioffset = zone->getRawOffset()/1000; |
| 961 UnicodeString offset, expectedID; | 961 UnicodeString offset, expectedID; |
| 962 formatOffset(ioffset, offset); | 962 formatOffset(ioffset, offset); |
| 963 formatTZID(ioffset, expectedID); | 963 formatTZID(ioffset, expectedID); |
| 964 logln(id + " -> " + itsID + " " + offset); | 964 logln(id + " -> " + itsID + " " + offset); |
| 965 if (exp == kUnparseable && itsID != "GMT") { | 965 if (exp == kUnparseable && itsID != "GMT") { |
| 966 errln("Expected parse failure for " + id + | 966 errln("Expected parse failure for " + id + |
| (...skipping 1003 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1970 } | 1970 } |
| 1971 } | 1971 } |
| 1972 delete zone; | 1972 delete zone; |
| 1973 } | 1973 } |
| 1974 if (sawAnError) { | 1974 if (sawAnError) { |
| 1975 dataerrln("***Note: Errors could be the result of changes to zoneStrings
locale data"); | 1975 dataerrln("***Note: Errors could be the result of changes to zoneStrings
locale data"); |
| 1976 } | 1976 } |
| 1977 } | 1977 } |
| 1978 | 1978 |
| 1979 #endif /* #if !UCONFIG_NO_FORMATTING */ | 1979 #endif /* #if !UCONFIG_NO_FORMATTING */ |
| OLD | NEW |