Closed
Bug 379528
Opened 17 years ago
Closed 13 years ago
Changing __proto__ causes uneval to throw with e.g. "RegExp.prototype.toSource called on incompatible global"
Categories
(Core :: JavaScript Engine, defect)
Core
JavaScript Engine
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: jruderman, Unassigned)
Details
(Keywords: testcase)
js> this.__proto__ = /r/ /r/ js> uneval(this) typein:2: TypeError: RegExp.prototype.toSource called on incompatible global
Reporter | ||
Comment 1•17 years ago
|
||
js> this.__proto__ = <x/> js> uneval(this) typein:2: TypeError: XML.prototype.toString called on incompatible global
Comment 2•17 years ago
|
||
(In reply to comment #0) > js> this.__proto__ = /r/ > /r/ > js> uneval(this) > typein:2: TypeError: RegExp.prototype.toSource called on incompatible global This is not a bug since RegExp.prototype.toSource is not generic and requires this to be regex. (In reply to comment #1) > js> this.__proto__ = <x/> > > js> uneval(this) > typein:2: TypeError: XML.prototype.toString called on incompatible global The bug here is why XML.prototype.toString and not XML.prototype.toSource is reported.
Comment 3•13 years ago
|
||
js> this.__proto__ = <x/> typein:3: TypeError: can't set prototype of an object to an XML value WFM?
OS: Mac OS X → All
Hardware: x86 → All
Comment 4•13 years ago
|
||
Sure, I think we can say that.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → WORKSFORME
Updated•13 years ago
|
Flags: in-testsuite?
You need to log in
before you can comment on or make changes to this bug.
Description
•