ericmckean / traceur-compiler

Automatically exported from code.google.com/p/traceur-compiler
Apache License 2.0
0 stars 0 forks source link

Default parameters do not work in generators #106

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Default parameter desugars to using arguments but arguments is not alpha 
renamed which causes bugs.

Original issue reported on code.google.com by arv@chromium.org on 25 Jun 2012 at 6:07

GoogleCodeExporter commented 9 years ago
function* f(x = 1) {
  yield x;
}

for (var x of f(42)) {
  console.log(x);
}

Original comment by arv@chromium.org on 25 Jun 2012 at 8:47

GoogleCodeExporter commented 9 years ago
https://code.google.com/p/traceur-compiler/source/detail?r=a09421513223816098d0c
ba4193d9924ecabb387

Original comment by arv@chromium.org on 10 Aug 2012 at 3:53