blob: bca25fb995bff521e4f2325b79dbd3eb4009d14e [file] [log] [blame]
Chris Lattner55196442007-11-20 19:04:50 +00001// RUN: clang -fsyntax-only -verify -pedantic %s
2
3int foo();
4int foo()
5{
6 return 0;
7}
8
9int bar();
10int bar(int i) // expected-error {{previous definition is here}}
11{
12 return 0;
13}
14int bar() // expected-error {{redefinition of 'bar'}}
15{
16 return 0;
17}
18
19int foobar(int); // expected-error {{previous definition is here}}
20int foobar() // expected-error {{redefinition of 'foobar'}}
21{
22 return 0;
23}
24
25int wibble(); // expected-error {{previous definition is here}}
26float wibble() // expected-error {{redefinition of 'wibble'}}
27{
28 return 0.0f;
29}