@@ -1267,20 +1267,6 @@ void GetZeroFillToggle(const FunctionCallbackInfo<Value>& args) {
12671267 args.GetReturnValue ().Set (Uint32Array::New (ab, 0 , 1 ));
12681268}
12691269
1270- void DetachArrayBuffer (const FunctionCallbackInfo<Value>& args) {
1271- Environment* env = Environment::GetCurrent (args);
1272- if (args[0 ]->IsArrayBuffer ()) {
1273- Local<ArrayBuffer> buf = args[0 ].As <ArrayBuffer>();
1274- if (buf->IsDetachable ()) {
1275- std::shared_ptr<BackingStore> store = buf->GetBackingStore ();
1276- if (buf->Detach (Local<Value>()).IsNothing ()) {
1277- return ;
1278- }
1279- args.GetReturnValue ().Set (ArrayBuffer::New (env->isolate (), store));
1280- }
1281- }
1282- }
1283-
12841270static void Btoa (const FunctionCallbackInfo<Value>& args) {
12851271 CHECK_EQ (args.Length (), 1 );
12861272 Environment* env = Environment::GetCurrent (args);
@@ -1570,7 +1556,6 @@ void Initialize(Local<Object> target,
15701556 &fast_index_of_number);
15711557 SetMethodNoSideEffect (context, target, " indexOfString" , IndexOfString);
15721558
1573- SetMethod (context, target, " detachArrayBuffer" , DetachArrayBuffer);
15741559 SetMethod (context, target, " copyArrayBuffer" , CopyArrayBuffer);
15751560
15761561 SetMethod (context, target, " swap16" , Swap16);
@@ -1680,7 +1665,6 @@ void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
16801665 registry->Register (StringWrite<UTF8>);
16811666 registry->Register (GetZeroFillToggle);
16821667
1683- registry->Register (DetachArrayBuffer);
16841668 registry->Register (CopyArrayBuffer);
16851669
16861670 registry->Register (Atob);
0 commit comments