Bug 86128

Summary: Error stack should not be read only
Product: WebKit Reporter: Erik Arvidsson <arv>
Component: JavaScriptCoreAssignee: Nobody <webkit-unassigned>
Status: RESOLVED CONFIGURATION CHANGED    
Severity: Normal CC: ashvayka, barraclough, beidson, oliver, saam
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 86442    
Bug Blocks: 85057    

Erik Arvidsson
Reported 2012-05-10 12:29:21 PDT
Both SpiderMonkey and V8 allows the stack property of error objects to be written to. try { throw new Error; } catch (ex) { ex.stack = 42; console.assert(e.stack === 42); } JSC fails because it treats stack as a read only property.
Attachments
Alexey Shvayka
Comment 1 2019-06-17 14:50:25 PDT
This is fixed as of rev. 246497. Property descriptor of "stack": { "value": "global code\\nevaluateWithScopeExtension@[native code]\\n\\n_wrapCall", "writable": true, // ! "enumerable": false, "configurable": true }
Sam Weinig
Comment 2 2021-04-21 14:18:08 PDT
*** Bug 86523 has been marked as a duplicate of this bug. ***
Note You need to log in before you can comment on or make changes to this bug.