>/  > * ArrayBuffer.isView
/>/  yup.  The use cases for isView aren't all that clear to me.  It could be
/>/  expressed a @@isView test if it has important use cases.
/

I'm not familiar enough with ArrayBuffers to understand the consequences.
By analogy with Array.isArray, if a proxy-for-arraybuffer automatically
upholds all observable invariants of ArrayBuffers, then arguably the test
should return true for proxies. What would be the observable invariants of
an ArrayBuffer?

ArrayBuffer.isView() should not return `true` for exotic array objects. That was just a spec bug, fixed in rev16 (https://bugs.ecmascript.org/show_bug.cgi?id=1570). As currently spec'ed, ArrayBuffer.isView() only returns true for TypedArray objects and DataView objects (both kind of objects have got a [[ViewedArrayBuffer]] internal data property). And there are no observable invariants which can be used for this case.


- André
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to