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

Do we need any syntax to leverage generators/promises coding patterns? #3815

Closed
Artazor opened this issue Jan 28, 2015 · 2 comments
Closed

Comments

@Artazor
Copy link
Contributor

Artazor commented Jan 28, 2015

I believe that JS community is agree that generators+promises coding patterns will be the next big thing in JavaScript development world. With such things as io.js it looks like the future already is here. And I want to start a discussion on possible new syntax and semantics of the corresponding language elements.

I invite you to take a brief look at the one of the possible implementations #3813, and provide a constructive critics for it, as well as discussion around it.

TL;DR - for demonstration I've implemented a toy feature (diamod arrows - see the test case) that allows concisely write async/await like functions. This feature interplays very well with CoffeeScript classes and inheritance and have a very small footprint (comparable with _extends utility). I agree that the syntax chosen is a bit ridiculous, but I want to discuss the semantics and the future general line rather than the particular syntax

@jashkenas
Copy link
Owner

Why open a ticket just to refer to another ticket? We can take a look at #3813 directly.

@Artazor
Copy link
Contributor Author

Artazor commented Jan 28, 2015

Sorry, I've thought that PR tickets without corresponding Issue ticket is not a normal situation. Will not do it again -)

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

No branches or pull requests

2 participants