| Index: src/apinatives.js
|
| diff --git a/src/apinatives.js b/src/apinatives.js
|
| index ca2bbf5c5355c53bb39ab249c7941adf284a6a39..a53617c523b24b7492f71ea684b7d3cf3cd66bba 100644
|
| --- a/src/apinatives.js
|
| +++ b/src/apinatives.js
|
| @@ -73,7 +73,15 @@ function InstantiateFunction(data, name) {
|
| if (name) %FunctionSetName(fun, name);
|
| cache[serialNumber] = fun;
|
| var prototype = %GetTemplateField(data, kApiPrototypeTemplateOffset);
|
| - fun.prototype = prototype ? Instantiate(prototype) : {};
|
| + var properties = %GetTemplateField(data, kApiPrototypePropertiesOffset);
|
| + if (properties != NONE) {
|
| + %IgnoreAttributesAndSetProperty(
|
| + fun, "prototype",
|
| + prototype ? Instantiate(prototype) : {},
|
| + properties);
|
| + } else {
|
| + fun.prototype = prototype ? Instantiate(prototype) : {};
|
| + }
|
| %SetProperty(fun.prototype, "constructor", fun, DONT_ENUM);
|
| var parent = %GetTemplateField(data, kApiParentTemplateOffset);
|
| if (parent) {
|
|
|