Repository: swc-project/swc (rust)

Issue:
Nested break/continue labels are broken when transforming to es5 
### Describe the bug

output code

```JavaScript
var _loop = function(i) {
    var _loop1 = function(j) {
        if (i < 2) return "continue|out";
        [
            1
        ].forEach(function(_) {
            console.log(i, j);
        });
    };
    for(var j = 0; j < 4; ++j){
        var _ret = _loop1(j);
        switch(_ret){
            case "continue|out":
                continue out;
        }
    }
};
out: for(var i = 0; i < 4; i++)_loop(i);
```

### Input code

```typescript
out: for (let i = 0; i < 4; i++) {
    for (let j = 0; j < 4; ++j) {
        if (i < 2) continue out;

        [1].forEach((_) => {
            console.log(i, j);
        });
    }
}
```


### Config

```json
{
  "sourceMaps": true,
  "jsc": {
    "parser": {
      "syntax": "ecmascript",
      "jsx": false
    },
    "preserveAllComments": true,
    "transform": null,
    "target": "es5",
    "loose": false,
    "externalHelpers": false,
    "keepClassNames": false,
    "minify": {
      "compress": false
    }
  },
  "isModule": true
}
```


### Playground link

[REPL](https://play.swc.rs/?version=1.2.163&code=H4sIAAAAAAAAA8svLbFSSMsvUtDISS1RyFSwVTCwBlI2CiZASltbU6GaSwEI4CqyICqyICq0tbNgKkAgM01BA6TXSFMhOT%2BvJDOvNFUhv7TEmguuItowVg9olmticoaGRrymgq0dknYQAOorzs9J1cvJT9fI1FHI0rSGS9dC2bVctQAQtOELtgAAAA%3D%3D&config=H4sIAAAAAAAAA0WOOw7CQAwF7%2BI6Lc12KA1NuIO1vKCA9yN7gxJFuTu7AkJnjZ9Gs5GlWT0Gzkau6IyOHubJbZRZDdouW2PhhRzBBzavUy7UZhWNLIa9o6yo4xfOIn0KAbEcuqIcbUwayMVZpALWO0rT2al6JCXD19QRlgKNLBdIhtrBn0Duhc2uHPDHYYrTuLZIn0KL%2BL32GjXZkG6z4FOyvwEeTGy97AAAAA%3D%3D)

### Expected behavior

print
```
2 0
2 1
2 2
2 3
3 0
3 1
3 2
3 3
```

### Actual behavior

Uncaught SyntaxError: Undefined label 'out'

### Version

1.2.163

### Additional context

_No response_

Pull request description:
fix(es/compat): nested for loop with break
<!-- Note: CI script will automatically rebase your PR so please do not rebase unless required -->

<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. -->

**Description:**

<!-- Explain the **motivation** for making this change. What existing problem does the pull request solve? -->

**BREAKING CHANGE:**

<!--
If this PR introduces a breaking change, it must contain a notice for it to be included in the CHANGELOG. Add description or remove entirely if not breaking.

You may need to update `MIGRATION.md` for the breaking changes.
-->

**Related issue (if exists):**
closes #4238 

Patch:
diff --git a/crates/swc_ecma_transforms_compat/src/es2015/block_scoping/mod.rs b/crates/swc_ecma_transforms_compat/src/es2015/block_scoping/mod.rs
index 72deab5137..6cce0e90f5 100644
--- a/crates/swc_ecma_transforms_compat/src/es2015/block_scoping/mod.rs
+++ b/crates/swc_ecma_transforms_compat/src/es2015/block_scoping/mod.rs
@@ -796,10 +796,6 @@ impl VisitMut for FlowHelper<'_> {
 
         match node {
             Stmt::Continue(ContinueStmt { label, .. }) => {
-                if self.in_nested_loop {
-                    return;
-                }
-
                 let value = if let Some(label) = label {
                     let value: JsWord = format!("continue|{}", label.sym).into();
                     self.label


Test patch:
diff --git a/crates/swc_ecma_transforms_compat/tests/block-scoping/issue-4238/1/input.js b/crates/swc_ecma_transforms_compat/tests/block-scoping/issue-4238/1/input.js
new file mode 100644
index 0000000000..cc9ff685fe
--- /dev/null
+++ b/crates/swc_ecma_transforms_compat/tests/block-scoping/issue-4238/1/input.js
@@ -0,0 +1,9 @@
+out: for (let i = 0; i < 4; i++) {
+    for (let j = 0; j < 4; ++j) {
+        if (i < 2) continue out;
+
+        [1].forEach((_) => {
+            console.log(i, j);
+        });
+    }
+}
diff --git a/crates/swc_ecma_transforms_compat/tests/block-scoping/issue-4238/1/output.js b/crates/swc_ecma_transforms_compat/tests/block-scoping/issue-4238/1/output.js
new file mode 100644
index 0000000000..036f1477b9
--- /dev/null
+++ b/crates/swc_ecma_transforms_compat/tests/block-scoping/issue-4238/1/output.js
@@ -0,0 +1,24 @@
+var _loop = function(i) {
+    var _loop1 = function(j) {
+        if (i < 2) return "continue|out";
+        [
+            1
+        ].forEach((_)=>{
+            console.log(i, j);
+        });
+    };
+    for(var j = 0; j < 4; ++j){
+        var _ret1 = _loop1(j);
+        switch(_ret1){
+            case "continue|out":
+                return "continue|out";
+        }
+    }
+};
+out: for(var i = 0; i < 4; i++){
+    var _ret = _loop(i);
+    switch(_ret){
+        case "continue|out":
+            continue out;
+    }
+}