Commit 7079e669 authored by neis's avatar neis Committed by Commit bot

Use HType::JSReceiver instead of HType::JSObject in some places.

R=bmeurer@chromium.org
BUG=

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

Cr-Commit-Position: refs/heads/master@{#32402}
parent 9334308a
...@@ -1524,7 +1524,7 @@ HValue* HChange::Canonicalize() { ...@@ -1524,7 +1524,7 @@ HValue* HChange::Canonicalize() {
HValue* HWrapReceiver::Canonicalize() { HValue* HWrapReceiver::Canonicalize() {
if (HasNoUses()) return NULL; if (HasNoUses()) return NULL;
if (receiver()->type().IsJSObject()) { if (receiver()->type().IsJSReceiver()) {
return receiver(); return receiver();
} }
return this; return this;
...@@ -1620,7 +1620,7 @@ HValue* HUnaryMathOperation::Canonicalize() { ...@@ -1620,7 +1620,7 @@ HValue* HUnaryMathOperation::Canonicalize() {
HValue* HCheckInstanceType::Canonicalize() { HValue* HCheckInstanceType::Canonicalize() {
if ((check_ == IS_JS_RECEIVER && value()->type().IsJSObject()) || if ((check_ == IS_JS_RECEIVER && value()->type().IsJSReceiver()) ||
(check_ == IS_JS_ARRAY && value()->type().IsJSArray()) || (check_ == IS_JS_ARRAY && value()->type().IsJSArray()) ||
(check_ == IS_STRING && value()->type().IsString())) { (check_ == IS_STRING && value()->type().IsString())) {
return value(); return value();
...@@ -3276,7 +3276,7 @@ bool HIsStringAndBranch::KnownSuccessorBlock(HBasicBlock** block) { ...@@ -3276,7 +3276,7 @@ bool HIsStringAndBranch::KnownSuccessorBlock(HBasicBlock** block) {
value()->type().IsNull() || value()->type().IsNull() ||
value()->type().IsBoolean() || value()->type().IsBoolean() ||
value()->type().IsUndefined() || value()->type().IsUndefined() ||
value()->type().IsJSObject()) { value()->type().IsJSReceiver()) {
*block = SecondSuccessor(); *block = SecondSuccessor();
return true; return true;
} }
......
...@@ -776,7 +776,7 @@ class HValue : public ZoneObject { ...@@ -776,7 +776,7 @@ class HValue : public ZoneObject {
bool ToStringOrToNumberCanBeObserved() const { bool ToStringOrToNumberCanBeObserved() const {
if (type().IsTaggedPrimitive()) return false; if (type().IsTaggedPrimitive()) return false;
if (type().IsJSObject()) return true; if (type().IsJSReceiver()) return true;
return !representation().IsSmiOrInteger32() && !representation().IsDouble(); return !representation().IsSmiOrInteger32() && !representation().IsDouble();
} }
...@@ -2880,7 +2880,7 @@ class HCheckInstanceType final : public HUnaryOperation { ...@@ -2880,7 +2880,7 @@ class HCheckInstanceType final : public HUnaryOperation {
HType CalculateInferredType() override { HType CalculateInferredType() override {
switch (check_) { switch (check_) {
case IS_JS_RECEIVER: return HType::JSObject(); case IS_JS_RECEIVER: return HType::JSReceiver();
case IS_JS_ARRAY: return HType::JSArray(); case IS_JS_ARRAY: return HType::JSArray();
case IS_JS_DATE: return HType::JSObject(); case IS_JS_DATE: return HType::JSObject();
case IS_STRING: return HType::String(); case IS_STRING: return HType::String();
......
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