Bug 1660405 - Move away from mozilla::IsNaN in favor of std::isnan. r=nbp,media-playback-reviewers,sergesanspaille,padenot

Differential Revision: https://phabricator.services.mozilla.com/D173035
This commit is contained in:
Andi-Bogdan Postelnicu
2023-03-22 09:27:56 +00:00
parent c3ec76bdbc
commit 5e0156c1e4
90 changed files with 236 additions and 253 deletions

View File

@@ -1832,7 +1832,7 @@ void HTMLInputElement::SetValueAsDate(JSContext* aCx,
// At this point we know we're not a file input, so we can just pass "not
// system" as the caller type, since the caller type only matters in the file
// input case.
if (IsNaN(milliseconds)) {
if (std::isnan(milliseconds)) {
SetValue(u""_ns, CallerType::NonSystem, aRv);
return;
}
@@ -1846,7 +1846,7 @@ void HTMLInputElement::SetValueAsDate(JSContext* aCx,
double year = JS::YearFromTime(milliseconds);
double month = JS::MonthFromTime(milliseconds);
if (IsNaN(year) || IsNaN(month)) {
if (std::isnan(year) || std::isnan(month)) {
SetValue(u""_ns, CallerType::NonSystem, aRv);
return;
}