ICU-96 more CE generation stuff, incremental compare, fixed currency test
X-SVN-Rev: 3953
This commit is contained in:
parent
bee28db988
commit
2ffeeafa59
@ -365,7 +365,7 @@ uint32_t uprv_uca_addAnElement(tempUCATable *t, UCAElements *element, UErrorCode
|
||||
uprv_cnttab_changeLastCE(contractions, CE, element->mapCE, TRUE, status);
|
||||
} else {
|
||||
#ifdef UCOL_DEBUG
|
||||
fprintf(stderr, "Warning - trying to overwrite already existing data for codepoint %04X\n", element->cPoints[0]);
|
||||
fprintf(stderr, "Warning - trying to overwrite existing data %08X for cp %04X with %08X\n", CE, element->cPoints[0], element->CEs[0]);
|
||||
//*status = U_ILLEGAL_ARGUMENT_ERROR;
|
||||
#endif
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -466,6 +466,7 @@ typedef struct {
|
||||
uint32_t firstMid; uint32_t lastMid; uint32_t midCount; uint32_t midByteCount;
|
||||
uint32_t firstLow; uint32_t lastLow; uint32_t lowCount; uint32_t lowByteCount;
|
||||
uint32_t byteSize; uint32_t start; uint32_t limit;
|
||||
int32_t maxCount;
|
||||
int32_t count;
|
||||
uint32_t current;
|
||||
uint32_t fLow; /*forbidden Low */
|
||||
@ -573,7 +574,7 @@ void ucol_setOptionsFromHeader(UCollator* result, const UCATableHeader * image,
|
||||
void ucol_putOptionsToHeader(UCollator* result, UCATableHeader * image, UErrorCode *status);
|
||||
|
||||
uint32_t ucol_getIncrementalUCA(UChar ch, incrementalContext *collationSource, UErrorCode *status);
|
||||
int32_t ucol_getIncrementalSpecialCE(const UCollator *coll, incrementalContext *ctx, UErrorCode *status);
|
||||
int32_t ucol_getIncrementalSpecialCE(const UCollator *coll, uint32_t CE, incrementalContext *ctx, UErrorCode *status);
|
||||
void ucol_updateInternalState(UCollator *coll);
|
||||
|
||||
#endif
|
||||
|
@ -35,6 +35,42 @@ void addCurrencyTest(TestNode** root)
|
||||
|
||||
void currTest()
|
||||
{
|
||||
/* All the currency symbols, in UCA order*/
|
||||
static const UChar currency[][2] =
|
||||
{
|
||||
{ 0x00A4, 0x0000}, /*00A4; L; [14 36, 03, 03] # [082B.0020.0002] # CURRENCY SIGN*/
|
||||
{ 0x00A2, 0x0000}, /*00A2; L; [14 38, 03, 03] # [082C.0020.0002] # CENT SIGN*/
|
||||
{ 0xFFE0, 0x0000}, /*FFE0; L; [14 38, 03, 05] # [082C.0020.0003] # FULLWIDTH CENT SIGN*/
|
||||
{ 0x0024, 0x0000}, /*0024; L; [14 3A, 03, 03] # [082D.0020.0002] # DOLLAR SIGN*/
|
||||
{ 0xFF04, 0x0000}, /*FF04; L; [14 3A, 03, 05] # [082D.0020.0003] # FULLWIDTH DOLLAR SIGN*/
|
||||
{ 0xFE69, 0x0000}, /*FE69; L; [14 3A, 03, 1D] # [082D.0020.000F] # SMALL DOLLAR SIGN*/
|
||||
{ 0x00A3, 0x0000}, /*00A3; L; [14 3C, 03, 03] # [082E.0020.0002] # POUND SIGN*/
|
||||
{ 0xFFE1, 0x0000}, /*FFE1; L; [14 3C, 03, 05] # [082E.0020.0003] # FULLWIDTH POUND SIGN*/
|
||||
{ 0x00A5, 0x0000}, /*00A5; L; [14 3E, 03, 03] # [082F.0020.0002] # YEN SIGN*/
|
||||
{ 0xFFE5, 0x0000}, /*FFE5; L; [14 3E, 03, 05] # [082F.0020.0003] # FULLWIDTH YEN SIGN*/
|
||||
{ 0x09F2, 0x0000}, /*09F2; L; [14 40, 03, 03] # [0830.0020.0002] # BENGALI RUPEE MARK*/
|
||||
{ 0x09F3, 0x0000}, /*09F3; L; [14 42, 03, 03] # [0831.0020.0002] # BENGALI RUPEE SIGN*/
|
||||
{ 0x0E3F, 0x0000}, /*0E3F; L; [14 44, 03, 03] # [0832.0020.0002] # THAI CURRENCY SYMBOL BAHT*/
|
||||
{ 0x17DB, 0x0000}, /*17DB; L; [14 46, 03, 03] # [0833.0020.0002] # KHMER CURRENCY SYMBOL RIEL*/
|
||||
{ 0x20A0, 0x0000}, /*20A0; L; [14 48, 03, 03] # [0834.0020.0002] # EURO-CURRENCY SIGN*/
|
||||
{ 0x20A1, 0x0000}, /*20A1; L; [14 4A, 03, 03] # [0835.0020.0002] # COLON SIGN*/
|
||||
{ 0x20A2, 0x0000}, /*20A2; L; [14 4C, 03, 03] # [0836.0020.0002] # CRUZEIRO SIGN*/
|
||||
{ 0x20A3, 0x0000}, /*20A3; L; [14 4E, 03, 03] # [0837.0020.0002] # FRENCH FRANC SIGN*/
|
||||
{ 0x20A4, 0x0000}, /*20A4; L; [14 50, 03, 03] # [0838.0020.0002] # LIRA SIGN*/
|
||||
{ 0x20A5, 0x0000}, /*20A5; L; [14 52, 03, 03] # [0839.0020.0002] # MILL SIGN*/
|
||||
{ 0x20A6, 0x0000}, /*20A6; L; [14 54, 03, 03] # [083A.0020.0002] # NAIRA SIGN*/
|
||||
{ 0x20A7, 0x0000}, /*20A7; L; [14 56, 03, 03] # [083B.0020.0002] # PESETA SIGN*/
|
||||
{ 0x20A9, 0x0000}, /*20A9; L; [14 58, 03, 03] # [083C.0020.0002] # WON SIGN*/
|
||||
{ 0xFFE6, 0x0000}, /*FFE6; L; [14 58, 03, 05] # [083C.0020.0003] # FULLWIDTH WON SIGN*/
|
||||
{ 0x20AA, 0x0000}, /*20AA; L; [14 5A, 03, 03] # [083D.0020.0002] # NEW SHEQEL SIGN*/
|
||||
{ 0x20AB, 0x0000}, /*20AB; L; [14 5C, 03, 03] # [083E.0020.0002] # DONG SIGN*/
|
||||
{ 0x20AC, 0x0000}, /*20AC; L; [14 5E, 03, 03] # [083F.0020.0002] # EURO SIGN*/
|
||||
{ 0x20AD, 0x0000}, /*20AD; L; [14 60, 03, 03] # [0840.0020.0002] # KIP SIGN*/
|
||||
{ 0x20AE, 0x0000}, /*20AE; L; [14 62, 03, 03] # [0841.0020.0002] # TUGRIK SIGN*/
|
||||
{ 0x20AF, 0x0000}, /*20AF; L; [14 64, 03, 03] # [0842.0020.0002] # DRACHMA SIGN*/
|
||||
};
|
||||
|
||||
#if 0
|
||||
/* All the currency symbols, in collation order*/
|
||||
static const UChar currency[][2] =
|
||||
{
|
||||
@ -57,6 +93,8 @@ void currTest()
|
||||
{ 0x20a9, 0x0000}, /* won*/
|
||||
{ 0x00a5, 0x0000} /* yen*/
|
||||
};
|
||||
#endif
|
||||
|
||||
UChar source[2], target[2];
|
||||
int32_t i, j, sortklen;
|
||||
int res;
|
||||
|
Loading…
Reference in New Issue
Block a user