Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1503)

Unified Diff: src/compiler/typer.cc

Issue 2306583002: [turbofan] Fix typing rule for Math.sign. (Closed)
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/type-cache.h ('k') | test/mjsunit/compiler/regress-math-sign-nan-type.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/typer.cc
diff --git a/src/compiler/typer.cc b/src/compiler/typer.cc
index 4f97772c8be20a0cb5b1553823d2abf749bab3f3..085b55482444f07d36c66c84efdbb0d2b276a486 100644
--- a/src/compiler/typer.cc
+++ b/src/compiler/typer.cc
@@ -1324,7 +1324,7 @@ Type* Typer::Visitor::JSCallFunctionTyper(Type* fun, Typer* t) {
case kMathTan:
return Type::Number();
case kMathSign:
- return t->cache_.kMinusOneToOne;
+ return t->cache_.kMinusOneToOneOrMinusZeroOrNaN;
// Binary math functions.
case kMathAtan2:
case kMathPow:
« no previous file with comments | « src/compiler/type-cache.h ('k') | test/mjsunit/compiler/regress-math-sign-nan-type.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698