Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Destructuring Assignment default value backward compatibility with coffeescript broken #171

Open
vird opened this issue Feb 5, 2016 · 2 comments

Comments

@vird
Copy link

vird commented Feb 5, 2016

{
  interval
  mod = 0
} = opt

coffeescript 1.10.0

var interval, mod, ref;

interval = opt.interval, mod = (ref = opt.mod) != null ? ref : 0;

iced 1.8.0-a (currently on http://maxtaco.github.io/coffee-script/)

Uncaught SyntaxError: unexpected =

serverside 108.0.9

error: unexpected =
  mod = 0
@maxtaco
Copy link
Owner

maxtaco commented Feb 5, 2016

I am thinking about moving all work to the iced3 branch, which requires
generators ( or piping output through regenerator / Babel ). What are your
thoughts?

On Thursday, February 4, 2016, vird [email protected] wrote:

{
interval
mod = 0
} = opt

coffeescript 1100

var interval, mod, ref;

interval = optinterval, mod = (ref = optmod) != null ? ref : 0;

iced 180-a (currently on http://maxtacogithubio/coffee-script/)

Uncaught SyntaxError: unexpected =

serverside 10809

error: unexpected =
mod = 0


Reply to this email directly or view it on GitHub
#171.

@doublerebel
Copy link

Came here looking for destructured arguments defaults too.

I am a heavy user of iced-coffee-script and would support moving to iced3. Generators are supported in Node since v4 and I'd bet anyone using iced for frontend (like myself) already has a build chain where Babel would be easy to add.

Thanks to coffee-script and Iced, I'm not clamoring for generators or other ES6 features. I know the rest of the JS world is moving in that direction though -- so I think iced3 is the most sustainable way forward, and the simpler syntax and compatibility would help iced adoption.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants