Brendan Eich wrote:
On May 14, 2009, at 1:47 PM, Waldemar Horwat wrote:

This whole thing is another nail in the coffin of generators. Generators are the root of the troublesome longjmp's which don't play well with others.

Are you talking about generators, or lambdas?

Generators.  They cause control flow to jump around between two independent 
functions.

THe same problem occurs without lambdas:

function gen(arg) {
 try {
   yield 1;
   yield 2;
 } finally {
   alert("Finally called up to three times?!");
 }
}

That finally will be called either 1, 2, or 3 times depending on what the 
caller does, which violates the principle that finally is called exactly once, 
no matter how you leave a scope.

   Waldemar
_______________________________________________
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to