incomplete-call.c revision 8c8d91917c307dc3ba4f60661377c745f2a6bef2
1// RUN: clang-cc -fsyntax-only -verify %s
2
3struct foo; // expected-note 3 {{forward declaration of 'struct foo'}}
4
5struct foo a(); // expected-note {{'a' declared here}}
6void b(struct foo);
7void c();
8
9void func() {
10  a(); // expected-error{{calling 'a' with incomplete return type 'struct foo'}}
11  b(*(struct foo*)0); // expected-error{{argument type 'struct foo' is incomplete}}
12  c(*(struct foo*)0); // expected-error{{argument type 'struct foo' is incomplete}}
13}
14