July 28 2015 Meeting Notes

Andy Wingo wingo at igalia.com
Thu Aug 6 13:24:34 UTC 2015


On Wed 05 Aug 2015 17:19, Rick Waldron <waldron.rick at gmail.com> writes:

> ## 6.7 new & GeneratorFunction 
>
> (Brian Terlson)
>
> [Slides](new-generator-function.pdf)
>
> BT: 
>
> Current Semantics: 
> - [[call]] `this` set normally by caller
> - [[construct]] `this` is a dynamic ReferenceError
> Issues:
> - Potentially confusing
> - new doesn't do anything useful
> Possible Solution:
> - GenerationFunction doesn't implement constructor, so new throws
> - `this` is not a dynamic ReferenceError, but instead refers to the
> GeneratorFunction instance (align with current implementations: Babel,
> V8, SM)

FWIW the behavior as implemented in V8 aligned at one point with a spec
draft:

  https://bugs.ecmascript.org/show_bug.cgi?id=1489

Andy


More information about the es-discuss mailing list