Re: April 10 2014 Meeting Notes

2014-04-27 Thread C. Scott Ananian
Certainly we could make `.return` always return `undefined` with no loss of
functionality, since the intended use case is simply to trigger `finally`
clauses and close the generator.
  --scott
​
___
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss


ES6 draft Rev24 now available

2014-04-27 Thread Allen Wirfs-Brock
At 
http://wiki.ecmascript.org/doku.php?id=harmony:specification_drafts#april_27_2014_draft_rev_24
 

Changes include:

• Several important bug fixes to Function Declaration Instantiation
• Updated RegExp so that subclasses that over-ride exec semantics don’t 
have to also over-ride match/replace/search
• disallowed a line break between ArrowParameters and the ⇒
• Adjust Array.prototype.reverse and Array.prototype.unshift to 
eliminate several unnecessary MOP calls that were exposed if the array is a 
proxy
• Object.assign now accepts multiple source arguments
• arguments object now have an @@iterator own property
• %TypedArray% constructors now processes iterables as an argument.
• Changed length property value of Symbol, Map, Set, WeakSet, WeakMap 
to 1 to be consistent with most other built-in constructors
• Added Annex B item about var declarations in catch clauses that 
binding the same name as a catch parameter
• Array.from/typedArray.from now calls filter function with two 
arguments.
• Eliminated static semantic rules that made the following an early 
error function({x}){var x} or generator(x) {var x}. A var declaration now can 
always be the same name as a formal parameter
• Made for (let x in x), etc. a TDZ violation
• further tweaking of super related productions in MemberExpression and 
NewExpression
• Bug fix in GetBindingValue to make TDZ work. Accessing an 
uninitialized binding always throws and is not conditional on strict mode.
• Started update of Annex A. Lexical grammar updated
• Resolved bugs: 2729, 2727, 2724-2722, 2714-2713, 2711-2706, 
2695-2688, 2685, 2681-2660, 2658-2657, 2655-2654, 2652-2649, 2647-2640, 
2638-2637, 2635-2613, 2611, 2608-2607, 2605-2604, 2600, 2573, 2566, 2561, 
2558-2557, 2551, 2548-2547, 2537, 2528-2526, 2477, 2445, 2443, 2337, 2314, 
2154, 2010, 1540, 1114___
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss


Re: April 10 2014 Meeting Notes

2014-04-27 Thread Brendan Eich

Mark S. Miller wrote:



BTW, return() should be idempotent. Is it?


Since .return takes an argument whose value is observable, I think not.

Hmmm. This is interestingly similar to multiple calls to resolve.


Yes, and note that Python's generator.close (no return value parameter, 
recall it throws a built-in exception, GeneratorExit, at the generator 
iterator) is idempotent. Calling it on a closed generator is a no-op.


This may be important for optimizability. Allen's speculation is that 
JITs can sort out early from "done" loop termination paths and 
maybe-call return only in the early cases, but I'm not so sure.


/be
___
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss