Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / CodeGenCoroutines / coro-function-try-block.cpp
blobf609eb55b8e771ffd64a1629e5c97f03e7f9c2b4
1 // RUN: %clang_cc1 -std=c++20 -triple=x86_64-- -emit-llvm -fcxx-exceptions \
2 // RUN: -disable-llvm-passes %s -o - | FileCheck %s
4 #include "Inputs/coroutine.h"
6 struct task {
7 struct promise_type {
8 task get_return_object();
9 std::suspend_never initial_suspend();
10 std::suspend_never final_suspend() noexcept;
11 void return_void();
12 void unhandled_exception() noexcept;
16 task f() try {
17 co_return;
18 } catch(...) {
21 // CHECK-LABEL: define{{.*}} void @_Z1fv(
22 // CHECK: call void @_ZNSt13suspend_never13await_suspendESt16coroutine_handleIvE(
23 // CHECK: call void @_ZN4task12promise_type11return_voidEv(