| Index: src/compiler/typer.cc
|
| diff --git a/src/compiler/typer.cc b/src/compiler/typer.cc
|
| index c43483dd409f877ba44e2aa272362853ef8e6db0..3625f5bd034dbc4d5bf1b31816143be3fed3cb1a 100644
|
| --- a/src/compiler/typer.cc
|
| +++ b/src/compiler/typer.cc
|
| @@ -248,6 +248,7 @@ class Typer::Visitor : public Reducer {
|
| static Type* NumberTrunc(Type*, Typer*);
|
| static Type* NumberToInt32(Type*, Typer*);
|
| static Type* NumberToUint32(Type*, Typer*);
|
| + static Type* NumberConvertHoleNaN(Type*, Typer*);
|
|
|
| static Type* ObjectIsCallable(Type*, Typer*);
|
| static Type* ObjectIsNumber(Type*, Typer*);
|
| @@ -556,6 +557,10 @@ Type* Typer::Visitor::NumberToUint32(Type* type, Typer* t) {
|
| return Type::Unsigned32();
|
| }
|
|
|
| +Type* Typer::Visitor::NumberConvertHoleNaN(Type* type, Typer* t) {
|
| + return Type::Union(type, Type::Undefined(), t->zone());
|
| +}
|
| +
|
| // Type checks.
|
|
|
| Type* Typer::Visitor::ObjectIsCallable(Type* type, Typer* t) {
|
| @@ -1813,6 +1818,10 @@ Type* Typer::Visitor::TypeNumberIsHoleNaN(Node* node) {
|
| return Type::Boolean();
|
| }
|
|
|
| +Type* Typer::Visitor::TypeNumberConvertHoleNaN(Node* node) {
|
| + return TypeUnaryOp(node, NumberConvertHoleNaN);
|
| +}
|
| +
|
| // static
|
| Type* Typer::Visitor::ReferenceEqualTyper(Type* lhs, Type* rhs, Typer* t) {
|
| if (lhs->IsConstant() && rhs->Is(lhs)) {
|
|
|