class-method-propname-constructor.js (460B)
1 // Copyright (C) 2015 the V8 project authors. All rights reserved. 2 // This code is governed by the BSD license found in the LICENSE file. 3 /*--- 4 es6id: 14.5.1 5 description: > 6 The opposite of: 7 8 ClassBody : ClassElementList 9 10 It is a Syntax Error if PrototypePropertyNameList of ClassElementList contains more than one occurrence of "constructor". 11 ---*/ 12 class A { 13 constructor() {} 14 } 15 16 assert.sameValue(typeof A, "function"); 17 18 19 reportCompare(0, 0);