blob: 8402d3829d7a5660c089e6b4fd44712d60a86e60 [file] [log] [blame]
Sean Hunt9ae60d52011-05-26 01:26:05 +00001// RUN: %clang_cc1 -fsyntax-only -verify %s
Sean Hunt0a629842011-06-03 18:05:29 +00002// RUN: %clang_cc1 -Wno-default-arg-special-member -Werror -fsyntax-only %s
Sean Hunt9ae60d52011-05-26 01:26:05 +00003
4class foo {
5 foo(foo&, int); // expected-note {{was not a special member function}}
6 foo(int); // expected-note {{was not a special member function}}
7 foo(const foo&); // expected-note {{was a copy constructor}}
8};
9
10foo::foo(foo&, int = 0) { } // expected-warning {{makes this constructor a copy constructor}}
11foo::foo(int = 0) { } // expected-warning {{makes this constructor a default constructor}}
12foo::foo(const foo& = 0) { } //expected-warning {{makes this constructor a default constructor}}