Files
TheRock/compiler/amd-llvm/clang/test/AST/ast-dump-labeled-break-continue.c
T
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

41 lines
1.8 KiB
C

// Test without serialization:
// RUN: %clang_cc1 -std=c2y -ast-dump %s \
// RUN: | FileCheck -strict-whitespace %s
//
// Test with serialization:
// RUN: %clang_cc1 -std=c2y -emit-pch -o %t %s
// RUN: %clang_cc1 -x c -std=c2y -include-pch %t -ast-dump-all /dev/null \
// RUN: | sed -e "s/ <undeserialized declarations>//" -e "s/ imported//" \
// RUN: | FileCheck -strict-whitespace %s
void TestLabeledBreakContinue() {
a: while (true) {
break a;
continue a;
c: for (;;) {
break a;
continue a;
break c;
}
}
}
// CHECK-LABEL: `-FunctionDecl {{.*}} TestLabeledBreakContinue
// CHECK-NEXT: `-CompoundStmt {{.*}} <col:33, line:21:1>
// CHECK-NEXT: `-LabelStmt {{.*}} <line:12:3, line:20:3> 'a'
// CHECK-NEXT: `-WhileStmt {{.*}} <line:12:6, line:20:3>
// CHECK-NEXT: |-CXXBoolLiteralExpr {{.*}} <line:12:13> 'bool' true
// CHECK-NEXT: `-CompoundStmt {{.*}} <col:19, line:20:3>
// CHECK-NEXT: |-BreakStmt {{.*}} <line:13:5, col:11> 'a' (WhileStmt {{.*}})
// CHECK-NEXT: |-ContinueStmt {{.*}} <line:14:5, col:14> 'a' (WhileStmt {{.*}})
// CHECK-NEXT: `-LabelStmt {{.*}} <line:15:5, line:19:5> 'c'
// CHECK-NEXT: `-ForStmt {{.*}} <line:15:8, line:19:5>
// CHECK-NEXT: |-<<<NULL>>>
// CHECK-NEXT: |-<<<NULL>>>
// CHECK-NEXT: |-<<<NULL>>>
// CHECK-NEXT: |-<<<NULL>>>
// CHECK-NEXT: `-CompoundStmt {{.*}} <line:15:17, line:19:5>
// CHECK-NEXT: |-BreakStmt {{.*}} <line:16:7, col:13> 'a' (WhileStmt {{.*}})
// CHECK-NEXT: |-ContinueStmt {{.*}} <line:17:7, col:16> 'a' (WhileStmt {{.*}})
// CHECK-NEXT: `-BreakStmt {{.*}} <line:18:7, col:13> 'c' (ForStmt {{.*}})