Closed Bug 350704 Opened 18 years ago Closed 18 years ago

Some "let" expressions in "for" initial-expression still become "let" statements above the "for"

Categories

(Core :: JavaScript Engine, defect, P1)

defect

Tracking

()

VERIFIED FIXED
mozilla1.8.1

People

(Reporter: jruderman, Assigned: brendan)

References

Details

(Keywords: testcase, verified1.8.1)

Attachments

(1 file)

> function() { try{} catch(y) { for(z(let(y=3)4); ; ) ; } }
function () { try { } catch (y) { let y = 3; for (z(4);;) { } } }

Attempting to recompile the result gives "redeclaration of variable y".

This is similar to bug 349605 and bug 348904.
Due to incomplete fix for bug 349605.  Patch next.

/be
OS: Mac OS X 10.4 → All
Hardware: Macintosh → All
Attached patch fixSplinter Review
Assignee: general → brendan
Status: NEW → ASSIGNED
Attachment #236114 - Flags: review?(mrbkap)
Blocks: js1.7let
Priority: -- → P1
Target Milestone: --- → mozilla1.8.1
Attachment #236114 - Flags: review?(mrbkap) → review+
Fixed on trunk.

Checking in jsemit.c;
/cvsroot/mozilla/js/src/jsemit.c,v  <--  jsemit.c
new revision: 3.191; previous revision: 3.190
done

/be
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Comment on attachment 236114 [details] [diff] [review]
fix

Another safe decompiler fix, really yet another forgotten case from bug 349605.

/be
Attachment #236114 - Flags: approval1.8.1?
Checking in regress-350704.js;
/cvsroot/mozilla/js/tests/js1_7/block/regress-350704.js,v  <--  regress-350704.js
initial revision: 1.1
Flags: in-testsuite+
verified fixed 1.9 20060831 windows/mac*/linux

I screwed up the test from this morning:
Checking in regress-350704.js;
/cvsroot/mozilla/js/tests/js1_7/block/regress-350704.js,v  <--  regress-350704.js
new revision: 1.2; previous revision: 1.1
done
Status: RESOLVED → VERIFIED
Comment on attachment 236114 [details] [diff] [review]
fix

a=beltzner on behalf of 181drivers
Attachment #236114 - Flags: approval1.8.1? → approval1.8.1+
Fixed on the 1.8 branch.

/be
Keywords: fixed1.8.1
verified fixed 1.9 20060901 windows/mac*/linux
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: