[docs] Add LICENSE.txt to the root of the mono-repo
[llvm-project.git] / clang / test / SemaCXX / invalid-decl.cpp
blob0cb8b00a8d129ae085c63b36b8afd610dc7b10a1
1 // RUN: %clang_cc1 -fsyntax-only -verify %s
3 class test1 {
4 template <typename> friend int bar(bool = true) {} // expected-note {{previous declaration is here}}
5 template <typename> friend int bar(bool); // expected-error {{friend declaration specifying a default argument must be the only declaration}}
6 };
8 class test2 {
9 friend int bar(bool = true) {} // expected-note {{previous declaration is here}}
10 friend int bar(bool); // expected-error{{friend declaration specifying a default argument must be the only declaration}}