Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / SemaCXX / linkage-invalid-decl.cpp
blob0a991baf9d7dc3f093621afcef2cfaee6e9ca3f8
1 // RUN: %clang_cc1 -fsyntax-only -verify %s
3 // This invalid declaration used to call infinite recursion in linkage
4 // calculation for enum as a function argument.
5 inline foo(A)(enum E;
6 // expected-error@-1 {{unknown type name 'foo'}}
7 // expected-error@-2 {{ISO C++ forbids forward references to 'enum' types}}
8 // expected-error@-3 {{expected ')'}}
9 // expected-note@-4 {{to match this '('}}