3916401e4b
This reverts commit14108f4c2e
. Reason for revert: Not the culprit for Canary microtask crashes Original change's description: > [builtins] Mega-revert to address the Dev blocker in crbug.com/808911. > > - Revert "[builtins] Save one word in contexts for Promise.all." > This reverts commit7632da067b
. > - Revert "[builtins] Also use the Promise#then protector for Promise#finally()." > This reverts commitd4f072ced3
. > - Revert "[builtins] Don't mess with entered context for MicrotaskCallbacks." > This reverts commit6703dacdd6
. > - Revert "[debugger] Properly deal with settled promises in catch prediction." > This reverts commit40dd065823
. > - Revert "[builtins] Widen the fast-path for Promise builtins." > This reverts commitdb0556b7e8
. > - Revert "[builtins] Unify PerformPromiseThen and optimize it with TurboFan." > This reverts commita582199c5e
. > - Revert "[builtins] Remove obsolete PromiseBuiltinsAssembler::AppendPromiseCallback." > This reverts commit6bf8885290
. > - Revert "[builtins] Turn NewPromiseCapability into a proper builtin." > This reverts commit313b490ddd
. > - Revert "[builtins] Inline InternalPromiseThen into it's only caller" > This reverts commitf7bd6a2fd6
. > - Revert "[builtins] Implement Promise#catch by really calling into Promise#then." > This reverts commitb23b098fa0
. > - Revert "[promise] Remove incorrect fast path" > This reverts commit0f6eafe855
. > - Revert "[builtins] Squeeze JSPromise::result and JSPromise::reactions into a single field." > This reverts commit8a677a2831
. > - Revert "[builtins] Refactor promises to reduce GC overhead." > This reverts commit8e7737cb58
. > > Tbr: hpayer@chromium.org > Bug: chromium:800651, chromium:808911, v8:5691, v8:7253 > Change-Id: I8c8ea5ed32ed62f6cd8b0d027a3707ddd891e5f1 > Cq-Include-Trybots: master.tryserver.chromium.linux:linux_chromium_rel_ng > Reviewed-on: https://chromium-review.googlesource.com/906991 > Commit-Queue: Yang Guo <yangguo@chromium.org> > Commit-Queue: Adam Klein <adamk@chromium.org> > Reviewed-by: Adam Klein <adamk@chromium.org> > Reviewed-by: Benedikt Meurer <bmeurer@chromium.org> > Cr-Commit-Position: refs/heads/master@{#51158} Change-Id: I09d958cbebd635a325809072a290f2f53df8c5d4 Tbr: adamk@chromium.org,yangguo@chromium.org,bmeurer@chromium.org Bug: chromium:800651, chromium:808911, v8:5691, v8:7253 Cq-Include-Trybots: master.tryserver.chromium.linux:linux_chromium_rel_ng Reviewed-on: https://chromium-review.googlesource.com/908988 Reviewed-by: Adam Klein <adamk@chromium.org> Commit-Queue: Adam Klein <adamk@chromium.org> Cr-Commit-Position: refs/heads/master@{#51181}
28 lines
555 B
JavaScript
28 lines
555 B
JavaScript
// Copyright 2018 the V8 project authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
//
|
|
// Flags: --allow-natives-syntax
|
|
|
|
var list = [];
|
|
function log(item) { list.push(item); }
|
|
async function f() {
|
|
try {
|
|
let namespace = await import(/a/);
|
|
} catch(e) {
|
|
log(1);
|
|
}
|
|
}
|
|
f();
|
|
|
|
async function g() {
|
|
try {
|
|
let namespace = await import({ get toString() { return undefined; }});
|
|
} catch(e) {
|
|
log(2);
|
|
}
|
|
}
|
|
g();
|
|
%RunMicrotasks();
|
|
assertEquals(list, [1,2]);
|