The Metrowerks compiler on the Symbian platform moves the globally defined Hashtables into read-only memory, despite one of the members being mutable. This causes crashes at run-time due to write access to read-only memory. This patch avoid the use of const with this compiler by introducing the JSC_CONST_HASHTABLE macro.
Created attachment 32066 [details] Patch to fix run-time crashes with winscw
Comment on attachment 32066 [details] Patch to fix run-time crashes with winscw Have we reported the issue to metroworks? It seems useful to have a link to an bug in their tracker (if such a thing exists) or some way of knowing when we can revert this. If this is the only way to fix this (modifying the source instead of passing an extra compiler flag or something), then this is totally a fine fix. It just would be nice to know when we can remove it.
Yes, the issue is being tracked upstream in the Carbide Bugzilla at https://xdabug001.ext.nokia.com/bugzilla/show_bug.cgi?id=8574 (the bugzilla seems to require account registration to see and comment on reports, but it's free for anyone) I'm all for removing the workaround as soon as the compiler is fixed and a new release is available.
Comment on attachment 32066 [details] Patch to fix run-time crashes with winscw r=me I would suggest maybe making the comment above JSC_CONST_HASHTABLE a bit shorter, just stating that it's a workaround for a compiler bug should do.
Landed in 45553