зеркало из https://github.com/mozilla/pjs.git
Fix for bug 146964 (Bug in format-number XSLT function). r=sicking, sr=jst.
This commit is contained in:
Родитель
069254688b
Коммит
e909955eea
|
@ -137,7 +137,6 @@ ExprResult* txFormatNumberFunctionCall::evaluate(Node* aContext,
|
|||
if (pos == formatLen) {
|
||||
pos = 0;
|
||||
prefix.append(format->mMinusSign);
|
||||
value = value * -1;
|
||||
}
|
||||
else
|
||||
pos++;
|
||||
|
@ -176,16 +175,6 @@ ExprResult* txFormatNumberFunctionCall::evaluate(Node* aContext,
|
|||
return new StringResult(err);
|
||||
}
|
||||
}
|
||||
else if (c == format->mMinusSign) {
|
||||
if (Double::isNeg(value))
|
||||
value=-1 * value;
|
||||
else {
|
||||
String err(INVALID_PARAM_VALUE);
|
||||
toString(err);
|
||||
aCs->recieveError(err);
|
||||
return new StringResult(err);
|
||||
}
|
||||
}
|
||||
else if (c == format->mDecimalSeparator ||
|
||||
c == format->mGroupingSeparator ||
|
||||
c == format->mZeroDigit ||
|
||||
|
|
Загрузка…
Ссылка в новой задаче