tint/hlsl: fix RemoveContinueInSwitch transform to handle nested switch statements

Rework the transform so that it handles a continue within a switch
nested within switches within a loop. Also make the transform only
generate a single bool variable per loop, rather than per continue
statement.

Bug: tint:1080
Change-Id: I626cf4aa35e900ccc8ad08712ff1393c91587f10
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/151041
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: Ben Clayton <bclayton@chromium.org>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: James Price <jrprice@google.com>
diff --git a/test/tint/loops/nested_loop_switch_loop_switch_switch.wgsl b/test/tint/loops/nested_loop_switch_loop_switch_switch.wgsl
new file mode 100644
index 0000000..c152681
--- /dev/null
+++ b/test/tint/loops/nested_loop_switch_loop_switch_switch.wgsl
@@ -0,0 +1,31 @@
+@compute @workgroup_size(1)
+fn main() {
+  var k = 0;
+  for (var i = 0; i < 2; i += 2) {
+    switch(i) {
+      case 0: {
+        for (var j = 0; j < 2; j += 2) {
+          switch(j) {
+            case 0: {
+              continue; // j loop
+            }
+            case 1: {
+              switch (k) {
+                case 0: {
+                  continue; // j loop
+                }
+                default: {
+                }
+              }
+            }
+            default: {
+            }
+          }
+        }
+        continue; // i loop
+      }
+      default: {
+      }
+    }
+  }
+}