{"action":"created","issue":{"url":"https://api.github.com/repos/tc39/ecmascript-asyncawait/issues/70","repository_url":"https://api.github.com/repos/tc39/ecmascript-asyncawait","labels_url":"https://api.github.com/repos/tc39/ecmascript-asyncawait/issues/70/labels{/name}","comments_url":"https://api.github.com/repos/tc39/ecmascript-asyncawait/issues/70/comments","events_url":"https://api.github.com/repos/tc39/ecmascript-asyncawait/issues/70/events","html_url":"https://github.com/tc39/ecmascript-asyncawait/issues/70","id":110530819,"number":70,"title":"Propose: Parallel await","user":{"login":"thr0w","id":376148,"avatar_url":"https://avatars.githubusercontent.com/u/376148?v=3","gravatar_id":"","url":"https://api.github.com/users/thr0w","html_url":"https://github.com/thr0w","followers_url":"https://api.github.com/users/thr0w/followers","following_url":"https://api.github.com/users/thr0w/following{/other_user}","gists_url":"https://api.github.com/users/thr0w/gists{/gist_id}","starred_url":"https://api.github.com/users/thr0w/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thr0w/subscriptions","organizations_url":"https://api.github.com/users/thr0w/orgs","repos_url":"https://api.github.com/users/thr0w/repos","events_url":"https://api.github.com/users/thr0w/events{/privacy}","received_events_url":"https://api.github.com/users/thr0w/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-10-08T20:05:53Z","updated_at":"2016-03-18T17:53:35Z","closed_at":"2015-10-08T20:46:33Z","body":"```javascript\r\n\r\nvar a = await {\r\n  yield 1;\r\n  yield 2;\r\n  yield 3;\r\n}\r\n\r\n// a == [1,2,3]\r\n```\r\n\r\n```javascript\r\n\r\nvar a = await {\r\n  for(var i=1;i<=3;i++)\r\n  {\r\n    yield i;\r\n  }\r\n}\r\n\r\n// a == [1,2,3]\r\n```\r\n\r\n```javascript\r\n// consider existing async function loadfile(filename)\r\n\r\nvar a = await {\r\n  for(var i=1;i<=3;i++)\r\n  {\r\n    var file_content = await loadfile(i+'.json')\r\n    yield JSON.parse(file_content);\r\n  }\r\n}\r\n\r\n// a is an array with contents of 1.json, 2.json and 3.json, every parsed to Javascript objects\r\n```\r\n\r\nImportant: This is just a draft. If you like this idea explain better in your standards.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/tc39/ecmascript-asyncawait/issues/comments/198469978","html_url":"https://github.com/tc39/ecmascript-asyncawait/issues/70#issuecomment-198469978","issue_url":"https://api.github.com/repos/tc39/ecmascript-asyncawait/issues/70","id":198469978,"user":{"login":"leonyu","id":304902,"avatar_url":"https://avatars.githubusercontent.com/u/304902?v=3","gravatar_id":"","url":"https://api.github.com/users/leonyu","html_url":"https://github.com/leonyu","followers_url":"https://api.github.com/users/leonyu/followers","following_url":"https://api.github.com/users/leonyu/following{/other_user}","gists_url":"https://api.github.com/users/leonyu/gists{/gist_id}","starred_url":"https://api.github.com/users/leonyu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leonyu/subscriptions","organizations_url":"https://api.github.com/users/leonyu/orgs","repos_url":"https://api.github.com/users/leonyu/repos","events_url":"https://api.github.com/users/leonyu/events{/privacy}","received_events_url":"https://api.github.com/users/leonyu/received_events","type":"User","site_admin":false},"created_at":"2016-03-18T17:53:35Z","updated_at":"2016-03-18T17:53:35Z","body":"Wouldn't this just be:  \r\n```js\r\nawait Promise.all([1, 2, 3])\r\n```"}}