xref: /minix3/external/bsd/llvm/dist/clang/test/SemaCXX/PR6618.cpp (revision f4a2713ac843a11c696ec80c0a5e3e5d80b4d338)
1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 -fsyntax-only -verify %s
2*f4a2713aSLionel Sambuc class bar; // expected-note {{forward declaration of 'bar'}}
3*f4a2713aSLionel Sambuc struct zed {
4*f4a2713aSLionel Sambuc   bar g; // expected-error {{field has incomplete type}}
5*f4a2713aSLionel Sambuc };
6*f4a2713aSLionel Sambuc class baz {
7*f4a2713aSLionel Sambuc   zed h;
8*f4a2713aSLionel Sambuc };
f()9*f4a2713aSLionel Sambuc void f() {
10*f4a2713aSLionel Sambuc   enum {
11*f4a2713aSLionel Sambuc     e = sizeof(baz)
12*f4a2713aSLionel Sambuc   };
13*f4a2713aSLionel Sambuc }
14