summaryrefslogtreecommitdiffstats
path: root/js/src/vm/ReceiverGuard.cpp
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@wolfbeast.com>2019-06-25 11:15:11 +0000
committerwolfbeast <mcwerewolf@wolfbeast.com>2019-06-25 11:15:11 +0000
commitc5b0e1f5e12f25613c95b0133883b774c22c8449 (patch)
tree70436d9a31f2510ec497475e1537c8091852d1a1 /js/src/vm/ReceiverGuard.cpp
parente2ab8d5f332cd26a072430fe1d1a4518cad15d1b (diff)
downloadUXP-c5b0e1f5e12f25613c95b0133883b774c22c8449.tar
UXP-c5b0e1f5e12f25613c95b0133883b774c22c8449.tar.gz
UXP-c5b0e1f5e12f25613c95b0133883b774c22c8449.tar.lz
UXP-c5b0e1f5e12f25613c95b0133883b774c22c8449.tar.xz
UXP-c5b0e1f5e12f25613c95b0133883b774c22c8449.zip
Remove Unboxed Object code from /vm, Part 3.
Diffstat (limited to 'js/src/vm/ReceiverGuard.cpp')
-rw-r--r--js/src/vm/ReceiverGuard.cpp14
1 files changed, 2 insertions, 12 deletions
diff --git a/js/src/vm/ReceiverGuard.cpp b/js/src/vm/ReceiverGuard.cpp
index e37bf8ee5..e95e8a208 100644
--- a/js/src/vm/ReceiverGuard.cpp
+++ b/js/src/vm/ReceiverGuard.cpp
@@ -15,11 +15,7 @@ ReceiverGuard::ReceiverGuard(JSObject* obj)
: group(nullptr), shape(nullptr)
{
if (obj) {
- if (obj->is<UnboxedPlainObject>()) {
- group = obj->group();
- if (UnboxedExpandoObject* expando = obj->as<UnboxedPlainObject>().maybeExpando())
- shape = expando->lastProperty();
- } else if (obj->is<TypedObject>()) {
+ if (obj->is<TypedObject>()) {
group = obj->group();
} else {
shape = obj->maybeShape();
@@ -32,9 +28,7 @@ ReceiverGuard::ReceiverGuard(ObjectGroup* group, Shape* shape)
{
if (group) {
const Class* clasp = group->clasp();
- if (clasp == &UnboxedPlainObject::class_) {
- // Keep both group and shape.
- } else if (IsTypedObjectClass(clasp)) {
+ if (IsTypedObjectClass(clasp)) {
this->shape = nullptr;
} else {
this->group = nullptr;
@@ -45,10 +39,6 @@ ReceiverGuard::ReceiverGuard(ObjectGroup* group, Shape* shape)
/* static */ int32_t
HeapReceiverGuard::keyBits(JSObject* obj)
{
- if (obj->is<UnboxedPlainObject>()) {
- // Both the group and shape need to be guarded for unboxed plain objects.
- return obj->as<UnboxedPlainObject>().maybeExpando() ? 0 : 1;
- }
if (obj->is<TypedObject>()) {
// Only the group needs to be guarded for typed objects.
return 2;