Awaiting thenables

Francisco Tolmasky tolmasky at
Fri Jun 26 18:40:39 UTC 2015

Out of curiosity, in ES7, would the following code:

console.log(await { then: function(x) { x(5) } })

Print out 5 then 6, or still 6 then 5? In other words, is the
asynchronousness gauranteed by the await, or by the underlying Promise

Francisco Tolmasky
tolmasky at
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list