Opened 16 years ago

Closed 15 years ago

#1582 closed defect (wontfix)

jslinker incorrectly handles for loop init without 'var'

Reported by: [email protected] Owned by: satish
Priority: high Milestone:
Component: BuildTools Version: 0.3
Keywords: jslinker Cc:
Blocked By: Blocking:


jslinker incorrectly handles for loops when multiple vars are initialised without using the var keyword.

Test case: for(i=0, j=0; i<1; i++) {}
Produces: for(i=0, j=0; i<1;i++
[notice the missing '){}']

Where as this: for(var i=0, j=0; i<1; i++) {}
Correctly produces: for(var i=0, j=0; i<1; i++){}

Initialising i and j prior to the loop does not fix the problem.

Change History (4)

comment:1 Changed 16 years ago by dylan

Component: GeneralBuildTools
Milestone: 0.5
Owner: changed from anonymous to satish

comment:2 Changed 15 years ago by Adam Peller

Satish, does this look like this will make 0.9?

comment:3 Changed 15 years ago by Adam Peller

Milestone: 0.9

I don't see jslinker ported to the new trunk. removing milestone. need an update on when to schedule this.

comment:4 Changed 15 years ago by Adam Peller

Resolution: wontfix
Status: newclosed

nobody owns this. punt

Note: See TracTickets for help on using tickets.