]> granicus.if.org Git - clang/commitdiff
Add a couple more tests.
authorEli Friedman <eli.friedman@gmail.com>
Thu, 20 Jun 2013 23:58:09 +0000 (23:58 +0000)
committerEli Friedman <eli.friedman@gmail.com>
Thu, 20 Jun 2013 23:58:09 +0000 (23:58 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@184501 91177308-0d34-0410-b5e6-96231b3b80d8

test/CXX/class.access/class.friend/p6.cpp
test/CXX/temp/temp.decls/temp.variadic/p5.cpp

index 7f7d9099032815163e6917a2c7fc0bf061d54c76..2fe20fe77fc8f2179e6f430a2c0233a7a0ebf9b8 100644 (file)
@@ -11,6 +11,10 @@ struct Y {
   friend void X::f2() { } // expected-error{{friend function definition cannot be qualified with 'X::'}}
 };
 
+template <typename T> struct Z {
+  friend void T::f() {} // expected-error{{friend function definition cannot be qualified with 'T::'}}
+};
+
 void local() {
   void f();
 
index 218990e9bb32478179b7ee865b9be58e437182e3..3681d7757e9435117e78fad8fa9b3daf2703c308 100644 (file)
@@ -165,6 +165,7 @@ template<typename T, typename... Types>
 struct alignas(Types) TestUnexpandedDecls : T{ // expected-error{{expression contains unexpanded parameter pack 'Types'}}
   void member_function(Types);  // expected-error{{declaration type contains unexpanded parameter pack 'Types'}}
   void member_function () throw(Types); // expected-error{{exception type contains unexpanded parameter pack 'Types'}}
+  void member_function2() noexcept(Types()); // expected-error{{expression contains unexpanded parameter pack 'Types'}}
   operator Types() const; // expected-error{{declaration type contains unexpanded parameter pack 'Types'}}
   Types data_member;  // expected-error{{data member type contains unexpanded parameter pack 'Types'}}
   static Types static_data_member; // expected-error{{declaration type contains unexpanded parameter pack 'Types'}}