brintos

brintos / llvm-project-archived public Read only

0
0
Text · 464 B · a16a7f8 Raw
20 lines · cpp
1// RUN: %clang_cc1 -fsyntax-only -verify -std=c++20 %s2 3#include "Inputs/std-coroutine.h"4 5namespace GH58172 {6template<typename Fn>7int f2(int, Fn&&)8{9  return 0;10}11 12int f1()13{14  return f2(v1, []() -> task<int> {   // expected-error {{no template named 'task'}} \15                                         expected-error {{use of undeclared identifier 'v1'}}16    co_return v2;                     // expected-error {{use of undeclared identifier 'v2'}}17  });18}19}20