Peeyush Kushwaha 72d83acc07 Properly convert continue statements in switch
Ignore just non-label break statements in a switch, and allow continue
statments and lablled break statements.

Fixes #5725
2017-05-25 13:49:29 +05:30

23 lines
283 B
JavaScript

let x, y;
{
a: let x;
let y;
}
switch (0) {
case 0: a: let x=0;
}
// it should break from inside of switch statements using labels
loop:
for (var i = 0; i < 10; i++) {
const z = 3; // force loop function
() => z;
switch(true) {
case true:
break loop;
}
}