diff options
Diffstat (limited to 'thirdparty/icu4c/common/ucnvscsu.cpp')
-rw-r--r-- | thirdparty/icu4c/common/ucnvscsu.cpp | 52 |
1 files changed, 26 insertions, 26 deletions
diff --git a/thirdparty/icu4c/common/ucnvscsu.cpp b/thirdparty/icu4c/common/ucnvscsu.cpp index 7b580291e1..86e850a998 100644 --- a/thirdparty/icu4c/common/ucnvscsu.cpp +++ b/thirdparty/icu4c/common/ucnvscsu.cpp @@ -163,7 +163,7 @@ _SCSUReset(UConverter *cnv, UConverterResetChoice choice) { /* reset toUnicode */ uprv_memcpy(scsu->toUDynamicOffsets, initialDynamicOffsets, 32); - scsu->toUIsSingleByteMode=TRUE; + scsu->toUIsSingleByteMode=true; scsu->toUState=readCommand; scsu->toUQuoteWindow=scsu->toUDynamicWindow=0; scsu->toUByteOne=0; @@ -174,7 +174,7 @@ _SCSUReset(UConverter *cnv, UConverterResetChoice choice) { /* reset fromUnicode */ uprv_memcpy(scsu->fromUDynamicOffsets, initialDynamicOffsets, 32); - scsu->fromUIsSingleByteMode=TRUE; + scsu->fromUIsSingleByteMode=true; scsu->fromUDynamicWindow=0; scsu->nextWindowUseIndex=0; @@ -371,7 +371,7 @@ singleByteMode: state=quotePairOne; } else if(b==SCU) { sourceIndex=nextSourceIndex; - isSingleByteMode=FALSE; + isSingleByteMode=false; goto fastUnicode; } else /* Srs */ { /* callback(illegal) */ @@ -508,17 +508,17 @@ fastUnicode: } else if(/* UC0<=b && */ b<=UC7) { dynamicWindow=(int8_t)(b-UC0); sourceIndex=nextSourceIndex; - isSingleByteMode=TRUE; + isSingleByteMode=true; goto fastSingle; } else if(/* UD0<=b && */ b<=UD7) { dynamicWindow=(int8_t)(b-UD0); - isSingleByteMode=TRUE; + isSingleByteMode=true; cnv->toUBytes[0]=b; cnv->toULength=1; state=defineOne; goto singleByteMode; } else if(b==UDX) { - isSingleByteMode=TRUE; + isSingleByteMode=true; cnv->toUBytes[0]=b; cnv->toULength=1; state=definePairOne; @@ -695,7 +695,7 @@ singleByteMode: } else if(b==SQU) { state=quotePairOne; } else if(b==SCU) { - isSingleByteMode=FALSE; + isSingleByteMode=false; goto fastUnicode; } else /* Srs */ { /* callback(illegal) */ @@ -805,17 +805,17 @@ fastUnicode: state=quotePairTwo; } else if(/* UC0<=b && */ b<=UC7) { dynamicWindow=(int8_t)(b-UC0); - isSingleByteMode=TRUE; + isSingleByteMode=true; goto fastSingle; } else if(/* UD0<=b && */ b<=UD7) { dynamicWindow=(int8_t)(b-UD0); - isSingleByteMode=TRUE; + isSingleByteMode=true; cnv->toUBytes[0]=b; cnv->toULength=1; state=defineOne; goto singleByteMode; } else if(b==UDX) { - isSingleByteMode=TRUE; + isSingleByteMode=true; cnv->toUBytes[0]=b; cnv->toULength=1; state=definePairOne; @@ -1159,7 +1159,7 @@ getTrailSingle: goto outputBytes; } else { /* change to Unicode mode and output this (lead, trail) pair */ - isSingleByteMode=FALSE; + isSingleByteMode=false; *target++=(uint8_t)SCU; if(offsets!=NULL) { *offsets++=sourceIndex; @@ -1218,7 +1218,7 @@ getTrailSingle: * switch to Unicode mode if this is the last character in the block * or there is at least one more ideograph following immediately */ - isSingleByteMode=FALSE; + isSingleByteMode=false; c|=SCU<<16; length=3; goto outputBytes; @@ -1269,13 +1269,13 @@ getTrailSingle: if(!(source<sourceLimit && (uint32_t)(*source-0x3400)<(0xd800-0x3400))) { if(((uint32_t)(c-0x30)<10 || (uint32_t)(c-0x61)<26 || (uint32_t)(c-0x41)<26)) { /* ASCII digit or letter */ - isSingleByteMode=TRUE; + isSingleByteMode=true; c|=((uint32_t)(UC0+dynamicWindow)<<8)|c; length=2; goto outputBytes; } else if((window=getWindow(scsu->fromUDynamicOffsets, c))>=0) { /* there is a dynamic window that contains this character, change to it */ - isSingleByteMode=TRUE; + isSingleByteMode=true; dynamicWindow=window; currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]; useDynamicWindow(scsu, dynamicWindow); @@ -1284,7 +1284,7 @@ getTrailSingle: goto outputBytes; } else if((code=getDynamicOffset(c, &offset))>=0) { /* define a dynamic window with this character */ - isSingleByteMode=TRUE; + isSingleByteMode=true; dynamicWindow=getNextDynamicWindow(scsu); currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]=offset; useDynamicWindow(scsu, dynamicWindow); @@ -1337,7 +1337,7 @@ getTrailUnicode: * the following character is not uncompressible, * change to the window */ - isSingleByteMode=TRUE; + isSingleByteMode=true; dynamicWindow=window; currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]; useDynamicWindow(scsu, dynamicWindow); @@ -1348,7 +1348,7 @@ getTrailUnicode: (code=getDynamicOffset(c, &offset))>=0 ) { /* two supplementary characters in (probably) the same window - define an extended one */ - isSingleByteMode=TRUE; + isSingleByteMode=true; code-=0x200; dynamicWindow=getNextDynamicWindow(scsu); currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]=offset; @@ -1645,7 +1645,7 @@ getTrailSingle: goto outputBytes; } else { /* change to Unicode mode and output this (lead, trail) pair */ - isSingleByteMode=FALSE; + isSingleByteMode=false; *target++=(uint8_t)SCU; --targetCapacity; c=((uint32_t)lead<<16)|trail; @@ -1701,7 +1701,7 @@ getTrailSingle: * switch to Unicode mode if this is the last character in the block * or there is at least one more ideograph following immediately */ - isSingleByteMode=FALSE; + isSingleByteMode=false; c|=SCU<<16; length=3; goto outputBytes; @@ -1746,13 +1746,13 @@ getTrailSingle: if(!(source<sourceLimit && (uint32_t)(*source-0x3400)<(0xd800-0x3400))) { if(((uint32_t)(c-0x30)<10 || (uint32_t)(c-0x61)<26 || (uint32_t)(c-0x41)<26)) { /* ASCII digit or letter */ - isSingleByteMode=TRUE; + isSingleByteMode=true; c|=((uint32_t)(UC0+dynamicWindow)<<8)|c; length=2; goto outputBytes; } else if((window=getWindow(scsu->fromUDynamicOffsets, c))>=0) { /* there is a dynamic window that contains this character, change to it */ - isSingleByteMode=TRUE; + isSingleByteMode=true; dynamicWindow=window; currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]; useDynamicWindow(scsu, dynamicWindow); @@ -1761,7 +1761,7 @@ getTrailSingle: goto outputBytes; } else if((code=getDynamicOffset(c, &offset))>=0) { /* define a dynamic window with this character */ - isSingleByteMode=TRUE; + isSingleByteMode=true; dynamicWindow=getNextDynamicWindow(scsu); currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]=offset; useDynamicWindow(scsu, dynamicWindow); @@ -1813,7 +1813,7 @@ getTrailUnicode: * the following character is not uncompressible, * change to the window */ - isSingleByteMode=TRUE; + isSingleByteMode=true; dynamicWindow=window; currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]; useDynamicWindow(scsu, dynamicWindow); @@ -1824,7 +1824,7 @@ getTrailUnicode: (code=getDynamicOffset(c, &offset))>=0 ) { /* two supplementary characters in (probably) the same window - define an extended one */ - isSingleByteMode=TRUE; + isSingleByteMode=true; code-=0x200; dynamicWindow=getNextDynamicWindow(scsu); currentOffset=scsu->fromUDynamicOffsets[dynamicWindow]=offset; @@ -1991,7 +1991,7 @@ _SCSUSafeClone(const UConverter *cnv, uprv_memcpy(&localClone->mydata, cnv->extraInfo, sizeof(SCSUData)); localClone->cnv.extraInfo = &localClone->mydata; - localClone->cnv.isExtraLocal = TRUE; + localClone->cnv.isExtraLocal = true; return &localClone->cnv; } @@ -2033,7 +2033,7 @@ static const UConverterStaticData _SCSUStaticData={ * substitution string. */ { 0x0e, 0xff, 0xfd, 0 }, 3, - FALSE, FALSE, + false, false, 0, 0, { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } /* reserved */ |