Bug 858131 - rewrite FloatingPoint.h to be C++-only instead of C-compatible C++; r+original-author=Waldo
This commit is contained in:
@@ -177,7 +177,7 @@ ValueFitsInInt32(const Value &v, int32_t *pi)
|
||||
*pi = v.toInt32();
|
||||
return true;
|
||||
}
|
||||
return v.isDouble() && MOZ_DOUBLE_IS_INT32(v.toDouble(), pi);
|
||||
return v.isDouble() && mozilla::DoubleIsInt32(v.toDouble(), pi);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -198,7 +198,7 @@ IsDefinitelyIndex(const Value &v, uint32_t *indexp)
|
||||
}
|
||||
|
||||
int32_t i;
|
||||
if (v.isDouble() && MOZ_DOUBLE_IS_INT32(v.toDouble(), &i) && i >= 0) {
|
||||
if (v.isDouble() && mozilla::DoubleIsInt32(v.toDouble(), &i) && i >= 0) {
|
||||
*indexp = uint32_t(i);
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user