mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-07 22:44:49 +00:00
ICU-10398 Fix uconfig test errors in ICU 52
X-SVN-Rev: 34404
This commit is contained in:
parent
c4a3dda5fc
commit
e5a9a38924
13 changed files with 23 additions and 19 deletions
|
@ -54,12 +54,10 @@ U_STABLE int32_t U_EXPORT2
|
|||
u_strlen(const UChar *s);
|
||||
#endif
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* \def U_STRING_CASE_MAPPER_DEFINED
|
||||
* @internal
|
||||
*/
|
||||
|
||||
#ifndef U_STRING_CASE_MAPPER_DEFINED
|
||||
#define U_STRING_CASE_MAPPER_DEFINED
|
||||
|
||||
|
@ -74,7 +72,6 @@ UStringCaseMapper(const UCaseMap *csm,
|
|||
UErrorCode *pErrorCode);
|
||||
|
||||
#endif
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
U_NAMESPACE_BEGIN
|
||||
|
||||
|
|
|
@ -350,7 +350,6 @@ private:
|
|||
void setCurrencyForSymbols();
|
||||
|
||||
public:
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* _Internal_ function - more efficient version of getSymbol,
|
||||
* returning a const reference to one of the symbol strings.
|
||||
|
@ -364,6 +363,7 @@ public:
|
|||
*/
|
||||
inline const UnicodeString &getConstSymbol(ENumberFormatSymbol symbol) const;
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* Returns that pattern stored in currecy info. Internal API for use by NumberFormat API.
|
||||
* @internal
|
||||
|
@ -458,10 +458,12 @@ DecimalFormatSymbols::getLocale() const {
|
|||
return locale;
|
||||
}
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
inline const UChar*
|
||||
DecimalFormatSymbols::getCurrencyPattern() const {
|
||||
return currPattern;
|
||||
}
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
U_NAMESPACE_END
|
||||
|
||||
|
|
|
@ -41,7 +41,6 @@
|
|||
#include "unicode/curramt.h"
|
||||
#include "unicode/enumset.h"
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* \def UNUM_DECIMALFORMAT_INTERNAL_SIZE
|
||||
* @internal
|
||||
|
@ -49,7 +48,6 @@
|
|||
#if UCONFIG_FORMAT_FASTPATHS_49
|
||||
#define UNUM_DECIMALFORMAT_INTERNAL_SIZE 16
|
||||
#endif
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
U_NAMESPACE_BEGIN
|
||||
|
||||
|
|
|
@ -505,7 +505,6 @@ public:
|
|||
*/
|
||||
Locale getLocale(ULocDataLocaleType type, UErrorCode& status) const;
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* Constants for capitalization context usage types.
|
||||
* @internal
|
||||
|
@ -528,7 +527,6 @@ public:
|
|||
kCapContextUsageMetazoneShort,
|
||||
kCapContextUsageTypeCount
|
||||
};
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
/**
|
||||
* ICU "poor man's RTTI", returns a UClassID for the actual class.
|
||||
|
|
|
@ -33,7 +33,6 @@ U_NAMESPACE_BEGIN
|
|||
class CharString;
|
||||
class DigitList;
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* \def UNUM_INTERNAL_STACKARRAY_SIZE
|
||||
* @internal
|
||||
|
@ -43,7 +42,6 @@ class DigitList;
|
|||
#else
|
||||
#define UNUM_INTERNAL_STACKARRAY_SIZE 128
|
||||
#endif
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
/**
|
||||
* Formattable objects can be passed to the Format class or
|
||||
|
@ -724,9 +722,11 @@ inline UnicodeString& Formattable::getString(void) {
|
|||
return *fValue.fString;
|
||||
}
|
||||
|
||||
#ifndef U_HIDE_DEPRECATED_API
|
||||
inline int32_t Formattable::getLong(UErrorCode* status) const {
|
||||
return getLong(*status);
|
||||
}
|
||||
#endif /* U_HIDE_DEPRECATED_API */
|
||||
|
||||
inline UFormattable* Formattable::toUFormattable() {
|
||||
return (UFormattable*)(this);
|
||||
|
|
|
@ -18,14 +18,12 @@
|
|||
|
||||
#include "unicode/utypes.h"
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* \def NUMSYS_NAME_CAPACITY
|
||||
* Size of a numbering system name.
|
||||
* @internal
|
||||
*/
|
||||
#define NUMSYS_NAME_CAPACITY 8
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -846,10 +846,12 @@ inline void RuleBasedCollator::setUCollator(UCollator *collator)
|
|||
setRuleStringFromCollator();
|
||||
}
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
inline const UCollator * RuleBasedCollator::getUCollator()
|
||||
{
|
||||
return ucollator;
|
||||
}
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
U_NAMESPACE_END
|
||||
|
||||
|
|
|
@ -1308,6 +1308,7 @@ inline void Transliterator::setID(const UnicodeString& id) {
|
|||
ID.truncate(ID.length()-1);
|
||||
}
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
inline Transliterator::Token Transliterator::integerToken(int32_t i) {
|
||||
Token t;
|
||||
t.integer = i;
|
||||
|
@ -1319,6 +1320,7 @@ inline Transliterator::Token Transliterator::pointerToken(void* p) {
|
|||
t.pointer = p;
|
||||
return t;
|
||||
}
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
U_NAMESPACE_END
|
||||
|
||||
|
|
|
@ -190,13 +190,11 @@ typedef enum UTimeZoneFormatGMTOffsetPatternType {
|
|||
UTZFMT_PAT_NEGATIVE_H,
|
||||
#endif /* U_HIDE_DRAFT_API */
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/**
|
||||
* Number of UTimeZoneFormatGMTOffsetPatternType types.
|
||||
* @internal
|
||||
*/
|
||||
UTZFMT_PAT_COUNT
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
} UTimeZoneFormatGMTOffsetPatternType;
|
||||
|
||||
/**
|
||||
|
|
|
@ -880,7 +880,7 @@ typedef enum UNumberFormatAttribute {
|
|||
* @draft ICU 51 */
|
||||
UNUM_SCALE = UNUM_LENIENT_PARSE + 2,
|
||||
#endif /* U_HIDE_DRAFT_API */
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
|
||||
/** Count of "regular" numeric attributes.
|
||||
* @internal */
|
||||
UNUM_NUMERIC_ATTRIBUTE_COUNT,
|
||||
|
@ -889,7 +889,6 @@ typedef enum UNumberFormatAttribute {
|
|||
* All items after this one are stored in boolean form.
|
||||
* @internal */
|
||||
UNUM_MAX_NONBOOLEAN_ATTRIBUTE = 0x0FFF,
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
|
||||
/** If 1, specifies that if setting the "max integer digits" attribute would truncate a value, set an error status rather than silently truncating.
|
||||
* For example, formatting the value 1234 with 4 max int digits would succeed, but formatting 12345 would fail. There is no effect on parsing.
|
||||
|
@ -905,11 +904,9 @@ typedef enum UNumberFormatAttribute {
|
|||
*/
|
||||
UNUM_PARSE_NO_EXPONENT,
|
||||
|
||||
#ifndef U_HIDE_INTERNAL_API
|
||||
/** Limit of boolean attributes.
|
||||
* @internal */
|
||||
UNUM_LIMIT_BOOLEAN_ATTRIBUTE
|
||||
#endif /* U_HIDE_INTERNAL_API */
|
||||
} UNumberFormatAttribute;
|
||||
|
||||
/**
|
||||
|
|
|
@ -1073,6 +1073,7 @@ static void TestDisplayNameBrackets()
|
|||
log_data_err("uloc_getDisplayName for displayLocale %s and namedLocale %s returns unexpected name or status %s\n", itemPtr->displayLocale, itemPtr->namedLocale, myErrorName(status));
|
||||
}
|
||||
|
||||
#if !UCONFIG_NO_FORMATTING
|
||||
status = U_ZERO_ERROR;
|
||||
uldn = uldn_open(itemPtr->displayLocale, ULDN_STANDARD_NAMES, &status);
|
||||
if (U_SUCCESS(status)) {
|
||||
|
@ -1092,6 +1093,7 @@ static void TestDisplayNameBrackets()
|
|||
} else {
|
||||
log_data_err("uldn_open fails for displayLocale %s, status=%s\n", itemPtr->displayLocale, u_errorName(status));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -814,7 +814,7 @@ void CharsetDetectionTest::Ticket6394Test() {
|
|||
// similar Windows and non-Windows SBCS encodings. State was kept in the shared
|
||||
// Charset Recognizer objects, and could be overwritten.
|
||||
void CharsetDetectionTest::Ticket6954Test() {
|
||||
#if !UCONFIG_NO_CONVERSION
|
||||
#if !UCONFIG_NO_CONVERSION && !UCONFIG_NO_FORMATTING
|
||||
UErrorCode status = U_ZERO_ERROR;
|
||||
UnicodeString sISO = "This is a small sample of some English text. Just enough to be sure that it detects correctly.";
|
||||
UnicodeString ssWindows("This is another small sample of some English text. Just enough to be sure that it detects correctly."
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include "toolutil.h"
|
||||
#include "ustrfmt.h"
|
||||
|
||||
#if !UCONFIG_NO_FORMATTING
|
||||
|
||||
#define DERB_VERSION "1.1"
|
||||
|
||||
#define DERB_DEFAULT_TRUNC 80
|
||||
|
@ -667,6 +669,14 @@ static void reportError(const char *pname, UErrorCode *status, const char *when)
|
|||
u_fprintf(ustderr, "%s: error %d while %s: %s\n", pname, *status, when, u_errorName(*status));
|
||||
}
|
||||
|
||||
#else
|
||||
extern int
|
||||
main(int argc, char* argv[]) {
|
||||
/* Changing stdio.h ustdio.h requires that formatting not be disabled. */
|
||||
return 3;
|
||||
}
|
||||
#endif /* !UCONFIG_NO_FORMATTING */
|
||||
|
||||
/*
|
||||
* Local Variables:
|
||||
* indent-tabs-mode: nil
|
||||
|
|
Loading…
Add table
Reference in a new issue