ICU-900 Fixed some compiler warnings.

X-SVN-Rev: 8334
This commit is contained in:
George Rhoten 2002-04-02 03:15:12 +00:00
parent 28377025b6
commit d950e15b50
4 changed files with 24 additions and 21 deletions

View File

@ -974,10 +974,10 @@ void TestGetLocale() {
int32_t i = 0;
struct {
char* requestedLocale;
char* validLocale;
char* actualLocale;
static const struct {
const char* requestedLocale;
const char* validLocale;
const char* actualLocale;
} testStruct[] = {
{ "sr_YU", "sr_YU", "root" },
{ "sh_YU", "sh_YU", "sh" },

View File

@ -51,10 +51,13 @@ TestCaseLower() {
uprv_memcmp(lowerRoot, buffer, length*U_SIZEOF_UCHAR)!=0 ||
buffer[length]!=0
) {
log_err("error in u_strToLower(root locale)=%ld error=%s string matches: %s\n",
log_err("error in u_strToLower(root locale)=%ld error=%s string matches: %s\t\nlowerRoot=%s\t\nbuffer=%s\n",
length,
u_errorName(errorCode),
uprv_memcmp(lowerRoot, buffer, length*U_SIZEOF_UCHAR)==0 && buffer[length]==0 ? "yes" : "no");
uprv_memcmp(lowerRoot, buffer, length*U_SIZEOF_UCHAR)==0 &&
buffer[length]==0 ? "yes" : "no",
aescstrdup(lowerRoot),
aescstrdup(buffer));
}
/* lowercase with turkish locale and in the same buffer */

View File

@ -1538,6 +1538,8 @@ enumCharNamesFn(void *context,
log_err("u_enumCharName(0x%lx - 1.0)=%s instead of %s\n", code, name, names[i].oldName);
}
break;
case U_CHAR_NAME_CHOICE_COUNT:
break;
}
break;
}
@ -1950,11 +1952,11 @@ static void TestUScriptCodeAPI(){
}
}
{
uint32_t i = 0;
UScriptCode code= USCRIPT_INVALID_CODE;
UErrorCode status = U_ZERO_ERROR;
int32_t err = 0;
for(;i<=0x10ffff;i++){
for(i = 0; i<=0x10ffff; i++){
code = uscript_getScript(i,&status);
if(code == USCRIPT_INVALID_CODE){
err++;
@ -1973,20 +1975,20 @@ static void TestUScriptCodeAPI(){
static void
TestAdditionalProperties() {
/* test data for u_charAge() */
static struct {
static const struct {
UChar32 c;
UVersionInfo version;
} charAges[]={
0x41, { 1, 1, 0, 0 },
0xffff, { 1, 1, 0, 0 },
0x20ab, { 2, 0, 0, 0 },
0x2fffe, { 2, 0, 0, 0 },
0x20ac, { 2, 1, 0, 0 },
0xfb1d, { 3, 0, 0, 0 },
0x3f4, { 3, 1, 0, 0 },
0x10300, { 3, 1, 0, 0 },
0x220, { 3, 2, 0, 0 },
0xff60, { 3, 2, 0, 0 }
{0x41, { 1, 1, 0, 0 }},
{0xffff, { 1, 1, 0, 0 }},
{0x20ab, { 2, 0, 0, 0 }},
{0x2fffe, { 2, 0, 0, 0 }},
{0x20ac, { 2, 1, 0, 0 }},
{0xfb1d, { 3, 0, 0, 0 }},
{0x3f4, { 3, 1, 0, 0 }},
{0x10300, { 3, 1, 0, 0 }},
{0x220, { 3, 2, 0, 0 }},
{0xff60, { 3, 2, 0, 0 }}
};
/* test data for u_hasBinaryProperty() */

View File

@ -2887,8 +2887,6 @@ TestFullRoundtrip(const char* cp){
TestConv(nsrc,3,cp,"",NULL,0);
for(;i<=0x10FFFF;i++){
int j =0;
if(i>=0xD800 && i<=0xDFFF){
continue;
}