-
Notifications
You must be signed in to change notification settings - Fork 13k
Implement await.ops #39224
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
Implement await.ops #39224
Conversation
You need pass all test and then we can pack this. |
Sorry! I have temporally disabled these tests to make it pass. (Since it's an early prototype). Can you pack it now? The build passed. Thanks! @Kingwl |
Let's try it! |
Hey @Kingwl, I've packed this into an installable tgz. You can install it for testing by referencing it in your
and then running There is also a playground for this build. |
reach stage 1! 🎉 |
src/compiler/parser.ts
Outdated
if (token() !== SyntaxKind.DotToken) return undefined; | ||
nextToken(); // advance past the dot | ||
if (!tokenIsIdentifierOrKeyword(token())) return undefined; | ||
const id = parseIdentifierName().escapedText; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
According to current spec, we should emit error when the identifier contains escape.
await . r\u{61}ce
is not an await operation expression.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's an early prototype and I'm not familiar with TS tokenizer/scanner so won't fix in the current stage
f4df92d
to
43e064b
Compare
withdraw the proposal |
withdraw rejected 🤔 |
close for now. I'll re-open and rebase this once the proposal gets advanced. |
Stage 1 ECMAScript proposal https://github.com/Jack-Works/proposal-await.ops