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

Side by Side Diff: test/mjsunit/harmony/async-arrow-lexical-super.js

Issue 1895603002: [esnext] prototype runtime implementation for async functions (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@AsyncFunction
Patch Set: remove weird arrow-generator thing Created 4 years, 7 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Flags: --harmony-async-await
6
7 class BaseClass {
8 constructor(x) {
9 this.name_ = x;
10 }
11 get name() { return this.name_; }
12 };
13
14 class DeferredSuperCall extends BaseClass {
15 constructor(x) {
16 return async() => super(x);
17 }
18 };
19
20 assertEqualsAsync(
21 "LexicalSuperCall",
22 new DeferredSuperCall("LexicalSuperCall")().then(x => x.name));
23
24
25 class DeferredSuperProperty extends BaseClass {
26 deferredName() { return async() => super.name; }
27 };
28
29 assertEqualsAsync(
30 "LexicalSuperProperty",
31 new DeferredSuperProperty("LexicalSuperProperty").deferredName()());
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698