reverted change back due to unexpected bugs...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2018-08-19 16:10:23 +03:00
parent d4fd394174
commit ff63091784
2 changed files with 5 additions and 5 deletions

View File

@ -186,10 +186,10 @@ function makeConstructor(name, a, b){
.replace(/Constructor/g, name)) .replace(/Constructor/g, name))
} }
// NOTE: we are not assigning to .__proto__ directly to preserve // XXX it turns out we can't directly assign to .constructor.prototype
// function metadata like it's name... // and by assigning directly to .__proto__ we lose some meta
//_constructor.__proto__ = cls_proto // information like function name...
_constructor.__proto__.__proto__ = cls_proto _constructor.__proto__ = cls_proto
_constructor.prototype = proto _constructor.prototype = proto
_constructor.prototype.constructor = _constructor _constructor.prototype.constructor = _constructor

View File

@ -1,6 +1,6 @@
{ {
"name": "ig-object", "name": "ig-object",
"version": "1.0.3", "version": "1.0.4",
"description": "", "description": "",
"main": "object.js", "main": "object.js",
"scripts": { "scripts": {