Bug 17247

Summary: Labelled continue/break can fail in some cases
Product: WebKit Reporter: Oliver Hunt <oliver>
Component: JavaScriptCoreAssignee: Darin Adler <darin>
Status: RESOLVED FIXED    
Severity: Normal CC: darin, ggaren, mjs
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
Attachments:
Description Flags
Testcase none

Oliver Hunt
Reported 2008-02-08 15:03:07 PST
JSC does not handle a continue or break to a label when there are multiple labels at that scope, eg. a: b: for (var foo = 1; foo < 10; foo++) { if (foo == 4) continue a; print("foo: "+foo); } execution ends up terminating at foo: 3, rather than continuing to to foo: 9
Attachments
Testcase (395 bytes, text/html)
2008-02-08 15:06 PST, Oliver Hunt
no flags
Oliver Hunt
Comment 1 2008-02-08 15:06:19 PST
Created attachment 19009 [details] Testcase Uses setTimeout to trigger the script running as otherwise firefox does not run it for some reason
Mark Rowe (bdash)
Comment 2 2008-02-08 15:53:10 PST
Darin Adler
Comment 3 2008-02-08 17:14:14 PST
Committed revision 30103.
Note You need to log in before you can comment on or make changes to this bug.