ICU-5445 Fix some compiler warnings.

X-SVN-Rev: 21817
This commit is contained in:
George Rhoten 2007-06-24 04:15:38 +00:00
parent fd263f86cf
commit fdc039a8bd
3 changed files with 8 additions and 8 deletions

View File

@ -906,15 +906,15 @@ void RBBITableBuilder::sortedAdd(UVector **vector, int32_t val) {
//
//-----------------------------------------------------------------------------
void RBBITableBuilder::setAdd(UVector *dest, UVector *source) {
int destOriginalSize = dest->size();
int sourceSize = source->size();
int32_t destOriginalSize = dest->size();
int32_t sourceSize = source->size();
int32_t di = 0;
void *(destS[16]), *(sourceS[16]); // Handle small cases without malloc
void **destH = 0, **sourceH = 0;
void **destBuff, **sourceBuff;
void **destLim, **sourceLim;
if (destOriginalSize > sizeof(destS)/sizeof(destS[0])) {
if (destOriginalSize > (int32_t)(sizeof(destS)/sizeof(destS[0]))) {
destH = (void **)uprv_malloc(sizeof(void *) * destOriginalSize);
destBuff = destH;
}
@ -926,7 +926,7 @@ void RBBITableBuilder::setAdd(UVector *dest, UVector *source) {
}
destLim = destBuff + destOriginalSize;
if (sourceSize > sizeof(sourceS)/sizeof(sourceS[0])) {
if (sourceSize > (int32_t)(sizeof(sourceS)/sizeof(sourceS[0]))) {
sourceH = (void **)uprv_malloc(sizeof(void *) * sourceSize);
sourceBuff = sourceH;
}

View File

@ -38,8 +38,8 @@ UOBJECT_DEFINE_RTTI_IMPLEMENTATION(RelativeDateFormat)
RelativeDateFormat::RelativeDateFormat(const RelativeDateFormat& other) :
DateFormat(other), fDateFormat(NULL), fTimeFormat(NULL), fCombinedFormat(NULL),
fDateStyle(other.fDateStyle), fTimeStyle(other.fTimeStyle), fLocale(other.fLocale),
fDatesLen(other.fDatesLen), fDayMin(other.fDayMin), fDayMax(other.fDayMax),
fDates(NULL)
fDayMin(other.fDayMin), fDayMax(other.fDayMax),
fDatesLen(other.fDatesLen), fDates(NULL)
{
if(other.fDateFormat != NULL) {
fDateFormat = (DateFormat*)other.fDateFormat->clone();

View File

@ -1942,8 +1942,8 @@ public:
virtual Transliterator* clone(void) const {
return new TestTrans(getID());
}
virtual void handleTransliterate(Replaceable& text, UTransPosition& offsets,
UBool isIncremental) const
virtual void handleTransliterate(Replaceable& /*text*/, UTransPosition& offsets,
UBool /*isIncremental*/) const
{
offsets.start = offsets.limit;
}