Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(582)

Unified Diff: src/parsing/parser.cc

Issue 2633353002: [async-await] Remove RejectPromiseNoDebugEvent (Closed)
Patch Set: Rebase on top of latest changes Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/js/async-await.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parsing/parser.cc
diff --git a/src/parsing/parser.cc b/src/parsing/parser.cc
index 07ad607d37ac382d0eb51a9d3a6ca2ace923c32c..dcb973da78ebc39f91b7f157621f37be41c66fad 100644
--- a/src/parsing/parser.cc
+++ b/src/parsing/parser.cc
@@ -3018,15 +3018,15 @@ Expression* Parser::BuildResolvePromise(Expression* value, int pos) {
}
Expression* Parser::BuildRejectPromise(Expression* value, int pos) {
- // %RejectPromiseNoDebugEvent(.promise, value, true), .promise
- // The NoDebugEvent variant disables the additional debug event for the
- // rejection since a debug event already happened for the exception that got
- // us here.
- ZoneList<Expression*>* args = new (zone()) ZoneList<Expression*>(2, zone());
+ // %promise_internal_reject(.promise, value, false), .promise
+ // Disables the additional debug event for the rejection since a debug event
+ // already happened for the exception that got us here.
+ ZoneList<Expression*>* args = new (zone()) ZoneList<Expression*>(3, zone());
args->Add(factory()->NewVariableProxy(PromiseVariable()), zone());
args->Add(value, zone());
+ args->Add(factory()->NewBooleanLiteral(false, pos), zone());
Expression* call_runtime = factory()->NewCallRuntime(
- Context::REJECT_PROMISE_NO_DEBUG_EVENT_INDEX, args, pos);
+ Context::PROMISE_INTERNAL_REJECT_INDEX, args, pos);
return factory()->NewBinaryOperation(
Token::COMMA, call_runtime,
factory()->NewVariableProxy(PromiseVariable()), pos);
« no previous file with comments | « src/js/async-await.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698