Closed Bug 344370 Opened 19 years ago Closed 19 years ago

let declaration in let statement shows assertion

Categories

(Core :: JavaScript Engine, defect, P2)

defect

Tracking

()

VERIFIED FIXED
mozilla1.8beta2

People

(Reporter: nanto, Assigned: mrbkap)

References

Details

(Keywords: verified1.8.1)

Attachments

(1 file, 1 obsolete file)

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; ja; rv:1.8.0.4) Gecko/20060508 Firefox/1.5.0.4 Build Identifier: If let declarations appear just in a let statement, an assertion is shown. Reproducible: Always Steps to Reproduce: js> let (a = 2) { let b = 3; [a, b]; } Actual Results: Assertion failure: fp->spbase + OBJ_BLOCK_DEPTH(cx, obj) == sp, at jsinterp.c:5947 Expected Results: 2,3
Assignee: general → mrbkap
Status: UNCONFIRMED → NEW
Ever confirmed: true
I have a patch and need to look it over once more. I'll attach it here for safekeping.
Status: NEW → ASSIGNED
OS: Windows XP → All
Priority: -- → P2
Hardware: PC → All
Target Milestone: --- → mozilla1.8beta2
Attached patch Proposed fix (obsolete) — Splinter Review
Attachment #229024 - Flags: review?(brendan)
Comment on attachment 229024 [details] [diff] [review] Proposed fix MAYBE_, not MAY_BE_ Macro indentation madness Set pn1->pn_pos = tc->blockNode->pn_pos when making a TOK_LEXICALSCOPE node. /be
Attachment #229024 - Flags: review?(brendan) → review+
Attached patch Updated patchSplinter Review
I added a rider to get the index right when we're looking at the second let declaration (starting at the current count instead of always at 0).
Attachment #229024 - Attachment is obsolete: true
Attachment #229694 - Flags: review?(brendan)
Comment on attachment 229694 [details] [diff] [review] Updated patch Looks good, thanks. /be
Attachment #229694 - Flags: review?(brendan) → review+
Fix checked into trunk.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Checking in regress-344370.js; /cvsroot/mozilla/js/tests/js1_7/block/regress-344370.js,v <-- regress-344370.js initial revision: 1.1
Flags: in-testsuite+
Do we want this on 1.8 as well? verified fixed 20060723 trunk windows/mac*/linux
Status: RESOLVED → VERIFIED
Comment on attachment 229694 [details] [diff] [review] Updated patch This patch has been on the trunk for a week. It has not caused any known regressions, and it fixes several bugs in let expressions. Despite the large amounts of code that it touches, it shouldn't actually affect anything other than let statements.
Attachment #229694 - Flags: approval1.8.1?
Comment on attachment 229694 [details] [diff] [review] Updated patch a=drivers. Please land this on the MOZILLA_1_8_BRANCH.
Attachment #229694 - Flags: approval1.8.1? → approval1.8.1+
Depends on: 345867
Fixed on the 1.8 branch.
Keywords: fixed1.8.1
verified fixed 1.8.1, 1.9 windows/mac(ppc|tel)/linux
Depends on: 348375
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: