From 8264393c32b56b324f185906d43fd445485d6021 Mon Sep 17 00:00:00 2001 From: Jeff Walden Date: Sun, 24 Jan 2016 23:41:39 -0800 Subject: [PATCH] Bug 1079844 - Rename JS_ARRAYBUFFER_NEUTERED_FLAG to use detachment terminology. r=sfink --HG-- extra : rebase_source : 73a7c001e495600b6581e78a21dde8ca14bf4fde --- js/src/builtin/TypedArray.js | 2 +- js/src/builtin/TypedObjectConstants.h | 2 +- js/src/vm/ArrayBufferObject.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/js/src/builtin/TypedArray.js b/js/src/builtin/TypedArray.js index eafc2fac452e..2ba8ed786dfe 100644 --- a/js/src/builtin/TypedArray.js +++ b/js/src/builtin/TypedArray.js @@ -32,7 +32,7 @@ function IsDetachedBuffer(buffer) { return false; var flags = UnsafeGetInt32FromReservedSlot(buffer, JS_ARRAYBUFFER_FLAGS_SLOT); - return (flags & JS_ARRAYBUFFER_NEUTERED_FLAG) !== 0; + return (flags & JS_ARRAYBUFFER_DETACHED_FLAG) !== 0; } function GetAttachedArrayBuffer(tarray) { diff --git a/js/src/builtin/TypedObjectConstants.h b/js/src/builtin/TypedObjectConstants.h index 3294938c5c9b..e1b6a0d029c4 100644 --- a/js/src/builtin/TypedObjectConstants.h +++ b/js/src/builtin/TypedObjectConstants.h @@ -28,7 +28,7 @@ #define JS_ARRAYBUFFER_FLAGS_SLOT 3 -#define JS_ARRAYBUFFER_NEUTERED_FLAG 0x4 +#define JS_ARRAYBUFFER_DETACHED_FLAG 0x4 /////////////////////////////////////////////////////////////////////////// // Slots for typed prototypes diff --git a/js/src/vm/ArrayBufferObject.h b/js/src/vm/ArrayBufferObject.h index e3d72b53aa26..31fa757cb45d 100644 --- a/js/src/vm/ArrayBufferObject.h +++ b/js/src/vm/ArrayBufferObject.h @@ -159,7 +159,7 @@ class ArrayBufferObject : public ArrayBufferObjectMaybeShared TYPED_OBJECT_VIEWS = 0x20 }; - static_assert(JS_ARRAYBUFFER_NEUTERED_FLAG == DETACHED, + static_assert(JS_ARRAYBUFFER_DETACHED_FLAG == DETACHED, "self-hosted code with burned-in constants must use the " "correct DETACHED bit value"); public: