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

Side by Side Diff: test/mjsunit/es6/classes.js

Issue 1858943002: Remove runtime flags for sloppy mode block scoping features (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased Created 4 years, 8 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
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Flags: --harmony-sloppy --harmony-function-name --allow-natives-syntax 5 // Flags: --allow-natives-syntax
6 6
7 (function TestBasics() { 7 (function TestBasics() {
8 var C = class C {} 8 var C = class C {}
9 assertEquals(typeof C, 'function'); 9 assertEquals(typeof C, 'function');
10 assertEquals(C.__proto__, Function.prototype); 10 assertEquals(C.__proto__, Function.prototype);
11 assertEquals(Object.prototype, Object.getPrototypeOf(C.prototype)); 11 assertEquals(Object.prototype, Object.getPrototypeOf(C.prototype));
12 assertEquals(Function.prototype, Object.getPrototypeOf(C)); 12 assertEquals(Function.prototype, Object.getPrototypeOf(C));
13 assertEquals('C', C.name); 13 assertEquals('C', C.name);
14 14
15 class D {} 15 class D {}
(...skipping 971 matching lines...) Expand 10 before | Expand all | Expand 10 after
987 testClassRestrictedProperties(ClassWithDefaultConstructor); 987 testClassRestrictedProperties(ClassWithDefaultConstructor);
988 testClassRestrictedProperties(Class); 988 testClassRestrictedProperties(Class);
989 testClassRestrictedProperties(DerivedClassWithDefaultConstructor); 989 testClassRestrictedProperties(DerivedClassWithDefaultConstructor);
990 testClassRestrictedProperties(DerivedClass); 990 testClassRestrictedProperties(DerivedClass);
991 testClassRestrictedProperties(class { method() {} }); 991 testClassRestrictedProperties(class { method() {} });
992 testClassRestrictedProperties(class { constructor() {} method() {} }); 992 testClassRestrictedProperties(class { constructor() {} method() {} });
993 testClassRestrictedProperties(class extends Class { }); 993 testClassRestrictedProperties(class extends Class { });
994 testClassRestrictedProperties( 994 testClassRestrictedProperties(
995 class extends Class { constructor() { super(); } }); 995 class extends Class { constructor() { super(); } });
996 })(); 996 })();
OLDNEW
« no previous file with comments | « test/mjsunit/es6/class-property-name-eval-arguments.js ('k') | test/mjsunit/es6/classes-derived-return-type.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698