Fix lower bound in JSLoadContext typer.

R=rossberg@chromium.org

Review URL: https://codereview.chromium.org/549133002

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@23777 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent c3e63ee9
......@@ -485,8 +485,6 @@ Bounds Typer::Visitor::TypeJSInstanceOf(Node* node) {
// JS context operators.
Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
// TODO(rossberg): Fix this once we actually use the lower bound anywhere.
#if 0
Bounds outer = OperandType(node, 0);
DCHECK(outer.upper->Maybe(Type::Internal()));
// TODO(rossberg): More precisely, instead of the above assertion, we should
......@@ -509,7 +507,7 @@ Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
if (context_type->IsConstant()) {
context = Handle<Context>::cast(context_type->AsConstant()->Value());
}
} else {
} else if (!context.is_null()) {
context = handle(context.ToHandleChecked()->previous(), isolate());
}
}
......@@ -521,9 +519,6 @@ Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
Type* lower = TypeConstant(value);
return Bounds(lower, Type::Any(zone()));
}
#else
return Bounds::Unbounded(zone());
#endif
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment