Comment #1 on issue 4140 by m...@bocoup.com: Generator method `prototype` property incorrectly defined as non-writable
https://code.google.com/p/v8/issues/detail?id=4140

This applies to generator function instances created via other declarative
forms, as well:

$ d8 -e "function* g() {} print(Object.getOwnPropertyDescriptor(g, 'prototype').writable);"
    false
$ d8 -e "print(Object.getOwnPropertyDescriptor(function*() {}, 'prototype').writable);"
    false
$ d8 -e "print(Object.getOwnPropertyDescriptor(function* g() {}, 'prototype').writable);"
    false

## 14.4.12 Runtime Semantics: InstantiateFunctionObject

GeneratorDeclaration : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }

  [...]
  5. Perform MakeConstructor(F, true, prototype).
  [...]


## 14.4.14 Runtime Semantics: Evaluation

GeneratorExpression : function * ( FormalParameters ) { GeneratorBody }

   [...]
   5. Perform MakeConstructor(closure, true, prototype).
   [...]

GeneratorExpression : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }

  [...]
  9. Perform MakeConstructor (closure, true, prototype).
  [...]


--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
--
v8-dev mailing list
v8-dev@googlegroups.com
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to