extensibility.js 494 B

1234567891011121314
  1. // Copyright (C) 2016 the V8 project authors. All rights reserved.
  2. // This code is governed by the BSD license found in the LICENSE file.
  3. /*---
  4. esid: sec-properties-of-the-generatorfunction-constructor
  5. description: Object extensibility
  6. info: |
  7. The value of the [[Extensible]] internal slot of the GeneratorFunction
  8. constructor is true.
  9. features: [generators]
  10. ---*/
  11. var GeneratorFunction = Object.getPrototypeOf(function*() {}).constructor;
  12. assert(Object.isExtensible(GeneratorFunction));