Re: ArrayBuffer neutering

2014-05-21 Thread Anne van Kesteren
On Wed, May 21, 2014 at 2:10 AM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: Why didn't you provide a isNeutered predicate? Note that per http://www.whatwg.org/specs/web-apps/current-work/multipage/common-dom-interfaces.html#transferable there's more objects that can be neutered. Once

Re: ArrayBuffer neutering

2014-05-21 Thread Dmitry Lomov
On Wed, May 21, 2014 at 2:10 AM, Allen Wirfs-Brock al...@wirfs-brock.comwrote: below On May 20, 2014, at 4:28 PM, Kenneth Russell wrote: On Tue, May 20, 2014 at 9:40 AM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: On May 20, 2014, at 8:37 AM, Anne van Kesteren wrote: On Tue, May

Re: Bytecode

2014-05-21 Thread joe
After writing an ES6-ES5 compiler, I've come to the conclusion that ES5 *is* an intermediary language. For dynamic, duck-typed languages it's not so bad. I always found the Dart people's arguments the most persuasive: https://www.dartlang.org/articles/why-not-bytecode/ Basically, any language

Specifying the Existential Operator using Abrupt Completion

2014-05-21 Thread Claude Pache
I have thought about the right semantics (and the issues) of the existential operator. user.getPlan?().value?.score; The intended semantics of `?` is that, whenever its LHS evaluates to `null` or `undefined`, the evaluation of the whole expression (or subexpression) is interrupted and

Re: Specifying the Existential Operator using Abrupt Completion

2014-05-21 Thread Andreas Rossberg
On 21 May 2014 14:33, Claude Pache claude.pa...@gmail.com wrote: I have thought about the right semantics (and the issues) of the existential operator. user.getPlan?().value?.score; The intended semantics of `?` is that, whenever its LHS evaluates to `null` or `undefined`, the

Re: ArrayBuffer neutering

2014-05-21 Thread Allen Wirfs-Brock
On May 21, 2014, at 2:02 AM, Dmitry Lomov wrote: Finally, I note that the current Khronos spec. doesn't provide much guidance in this regard. The thing it has that is most similar to the other array methods is the 'subarray' method and it doesn't explicitly say anything about

Re: Specifying the Existential Operator using Abrupt Completion

2014-05-21 Thread Allen Wirfs-Brock
On May 21, 2014, at 5:56 AM, Andreas Rossberg wrote: On 21 May 2014 14:33, Claude Pache claude.pa...@gmail.com wrote: I have thought about the right semantics (and the issues) of the existential operator. user.getPlan?().value?.score; The intended semantics of `?` is that,

Re: ArrayBuffer neutering

2014-05-21 Thread Dmitry Lomov
On Wed, May 21, 2014 at 5:19 PM, Allen Wirfs-Brock al...@wirfs-brock.comwrote: On May 21, 2014, at 2:02 AM, Dmitry Lomov wrote: Finally, I note that the current Khronos spec. doesn't provide much guidance in this regard. The thing it has that is most similar to the other array methods

Re: ArrayBuffer neutering

2014-05-21 Thread Allen Wirfs-Brock
On May 21, 2014, at 9:59 AM, Dmitry Lomov wrote: On Wed, May 21, 2014 at 5:19 PM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: On May 21, 2014, at 2:02 AM, Dmitry Lomov wrote: Finally, I note that the current Khronos spec. doesn't provide much guidance in this regard.

Re: ArrayBuffer neutering

2014-05-21 Thread Kenneth Russell
On Tue, May 20, 2014 at 5:10 PM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: below On May 20, 2014, at 4:28 PM, Kenneth Russell wrote: On Tue, May 20, 2014 at 9:40 AM, Allen Wirfs-Brock al...@wirfs-brock.com wrote: On May 20, 2014, at 8:37 AM, Anne van Kesteren wrote: On Tue, May 20,

Re: ArrayBuffer neutering

2014-05-21 Thread C. Scott Ananian
On Wed, May 21, 2014 at 9:59 AM, Dmitry Lomov dslo...@chromium.org wrote: I think it would be weird if some of them fail hard and some would behave as if the length is zero. Consistency is always good. Why fail hard is more desirable? It is desirable because it allows for more efficient

Re: ArrayBuffer neutering

2014-05-21 Thread Jeremy Martin
I think it is better to have one legacy method that behaves differently from all the other (new) methods then to maintain consistency by introducing 20+ new bug farms. Is it too late (or too unexpected) for aTypedArray.subarray(aNeuteredObject)to throw in new contexts (i.e., modules,

Re: ArrayBuffer neutering

2014-05-21 Thread Allen Wirfs-Brock
On May 21, 2014, at 5:51 PM, Jeremy Martin wrote: I think it is better to have one legacy method that behaves differently from all the other (new) methods then to maintain consistency by introducing 20+ new bug farms. Is it too late (or too unexpected) for