From 22d5fed3420e7783596cc4bb849ce8857f0be0c2 Mon Sep 17 00:00:00 2001 From: Luke Wagner Date: Sat, 29 Oct 2016 09:37:55 -0500 Subject: Prevent detachment of a Memory's ArrayBuffer (#843) --- JS.md | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'JS.md') diff --git a/JS.md b/JS.md index a8b94d7..590e6be 100644 --- a/JS.md +++ b/JS.md @@ -451,6 +451,10 @@ aliases `m` and whose [[[ArrayBufferByteLength]]](http://tc39.github.io/ecma262/#sec-properties-of-the-arraybuffer-prototype-object) is set to the byte length of `m`. +Any attempts to [`detach`](http://tc39.github.io/ecma262/#sec-detacharraybuffer) `buffer` *other* than +the detachment performed by [`m.grow`](#webassemblymemoryprototypegrow) shall throw a +[`TypeError`](https://tc39.github.io/ecma262/#sec-native-error-types-used-in-this-standard-typeerror) + Return a new `WebAssembly.Memory` instance with [[Memory]] set to `m` and [[BufferObject]] set to `buffer`. -- cgit v1.2.3