Closed Bug 589318 Opened 15 years ago Closed 15 years ago

guard that eval-in-function frames don't access args

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: luke, Assigned: luke)

References

Details

(Whiteboard: fixed-in-tracemonkey)

Attachments

(1 file)

Attached patch patchSplinter Review
Currently, the frame for an eval executed in a function has fp->argc == fp->down->argc and fp->argv == fp->down->argv. However, our code doesn't really use this: argv/argc use isn't made by the script since its eval and must use JSOP_NAME; arguments-object access explicitly skips eval frames. This is very good and bug 539144 takes advantage of this: with argv removed, eval-in-function frames only need a copy of the down-frame's (callee, this), and the eval-in-function's argc is 0. I'd like to get this change reviewed/pushed separately: this patch makes the change without actually removing argv, and asserts that we never access the arguments of an eval-in-function frame. r?brendan, since he was so enthusiastic in bug 585231 comment 2.
Attachment #467923 - Flags: review?(brendan)
Comment on attachment 467923 [details] [diff] [review] patch I wonder if anyone will notice the exception .stack change. Let's find out! /be
Attachment #467923 - Flags: review?(brendan) → review+
I like your attitude!
Whiteboard: fixed-in-tracemonkey
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: