Closed
Bug 1313392
Opened 9 years ago
Closed 1 years ago
Consider decompiling bytecode to generate read-only errors.
Categories
(Core :: JavaScript Engine, defect, P3)
Core
JavaScript Engine
Tracking
()
RESOLVED
INCOMPLETE
People
(Reporter: emilio, Unassigned)
References
Details
(Keywords: triage-deferred)
Attachments
(1 file)
4.04 KB,
patch
|
Details | Diff | Splinter Review |
Spawned from bug 1304638, Nicolas suggested using the same mechanism to generate the normal error message.
See https://bugzilla.mozilla.org/show_bug.cgi?id=1304638#c31
Reporter | ||
Comment 1•9 years ago
|
||
Whoops, filled the bug from the wrong template.
No longer blocks: stylo
Reporter | ||
Comment 2•9 years ago
|
||
This was the patch from bug 1304638.
Attachment #8805159 -
Flags: review?(jwalden+bmo)
Updated•8 years ago
|
Attachment #8805159 -
Flags: review?(jwalden+bmo) → review?(nicolas.b.pierron)
Comment 3•8 years ago
|
||
Comment on attachment 8805159 [details] [diff] [review]
Patch
Review of attachment 8805159 [details] [diff] [review]:
-----------------------------------------------------------------
::: js/src/jsapi.cpp
@@ +153,5 @@
> +static bool
> +LastFrameIsFunctionCall(JSContext* cx)
> +{
> + FrameIter iter(cx);
> + jsbytecode* pc = iter.pc();
"iter.pc()" is valid iff there is a frame. These function call can be probably be made while using the jsapi, and this might trouble embedders to have either an assertion, or a crash on the next line. Guard this with "!iter.done()" condition.
@@ +154,5 @@
> +LastFrameIsFunctionCall(JSContext* cx)
> +{
> + FrameIter iter(cx);
> + jsbytecode* pc = iter.pc();
> + return (JSOp)*pc == JSOP_FUNCALL;
This sounds incomplete, any reason why this only includes "fun.call(…)" and not "fun(…)" ?
Can you use "IsCallPC" function here?
Attachment #8805159 -
Flags: review?(nicolas.b.pierron)
Updated•8 years ago
|
Keywords: triage-deferred
Priority: -- → P3
Updated•3 years ago
|
Severity: normal → S3
Updated•1 years ago
|
Status: NEW → RESOLVED
Closed: 1 years ago
Resolution: --- → INCOMPLETE
You need to log in
before you can comment on or make changes to this bug.
Description
•