diff options
author | Roman Divacky <rdivacky@FreeBSD.org> | 2010-01-01 10:34:51 +0000 |
---|---|---|
committer | Roman Divacky <rdivacky@FreeBSD.org> | 2010-01-01 10:34:51 +0000 |
commit | abe15e553e58165e7692c0d0842865c488ed7b45 (patch) | |
tree | 1e68501209c9133fbda8d45171e59f8d6f12dd55 /test/CXX/temp | |
parent | 34d02d0b37f16015f317a935c48ce8b7b64ae77b (diff) | |
download | src-abe15e553e58165e7692c0d0842865c488ed7b45.tar.gz src-abe15e553e58165e7692c0d0842865c488ed7b45.zip |
Updaet clang to 92395.
Notes
Notes:
svn path=/vendor/clang/dist/; revision=201361
Diffstat (limited to 'test/CXX/temp')
80 files changed, 139 insertions, 104 deletions
diff --git a/test/CXX/temp/temp.decls/temp.class.spec/p6.cpp b/test/CXX/temp/temp.decls/temp.class.spec/p6.cpp index 79d6c54e29f0..a93249e2268d 100644 --- a/test/CXX/temp/temp.decls/temp.class.spec/p6.cpp +++ b/test/CXX/temp/temp.decls/temp.class.spec/p6.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // Test class template partial specializations of member templates. template<typename T> diff --git a/test/CXX/temp/temp.decls/temp.class.spec/temp.class.order/p2.cpp b/test/CXX/temp/temp.decls/temp.class.spec/temp.class.order/p2.cpp index b3b7635106c5..cfa14f996bbe 100644 --- a/test/CXX/temp/temp.decls/temp.class.spec/temp.class.order/p2.cpp +++ b/test/CXX/temp/temp.decls/temp.class.spec/temp.class.order/p2.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<int I, int J, class T> class X { static const int value = 0; }; diff --git a/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1-neg.cpp b/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1-neg.cpp index 47cf8379c319..59253db3c529 100644 --- a/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1-neg.cpp +++ b/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1-neg.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T, int N> struct A; diff --git a/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1.cpp b/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1.cpp index 90bb16256c5b..87e21e4af845 100644 --- a/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1.cpp +++ b/test/CXX/temp/temp.decls/temp.class.spec/temp.class.spec.mfunc/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T, int N> struct A; diff --git a/test/CXX/temp/temp.decls/temp.class/temp.mem.class/p1.cpp b/test/CXX/temp/temp.decls/temp.class/temp.mem.class/p1.cpp index bc4bb5da4011..b65e1d0194b6 100644 --- a/test/CXX/temp/temp.decls/temp.class/temp.mem.class/p1.cpp +++ b/test/CXX/temp/temp.decls/temp.class/temp.mem.class/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T, typename U> struct X0 { diff --git a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1-retmem.cpp b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1-retmem.cpp index fd3fb0bc7a7d..4c05c622926d 100644 --- a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1-retmem.cpp +++ b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1-retmem.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X1 { }; diff --git a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1.cpp b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1.cpp index 6c827209ef0e..17645639fb82 100644 --- a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1.cpp +++ b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T, typename U> // expected-note{{previous template}} class X0 { public: diff --git a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1inst.cpp b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1inst.cpp index a09d0efa297f..f09faa90d5f9 100644 --- a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1inst.cpp +++ b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/p1inst.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // Test instantiation of member functions of class templates defined out-of-line template<typename T, typename U> struct X0 { diff --git a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp index 602fd374c2ab..70c9c70a41c0 100644 --- a/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp +++ b/test/CXX/temp/temp.decls/temp.class/temp.mem.func/pr5056.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s extern "C" void * malloc(int); diff --git a/test/CXX/temp/temp.decls/temp.class/temp.static/p1-inst.cpp b/test/CXX/temp/temp.decls/temp.class/temp.static/p1-inst.cpp index 2ddb8eac6c0a..aa53ebc58025 100644 --- a/test/CXX/temp/temp.decls/temp.class/temp.static/p1-inst.cpp +++ b/test/CXX/temp/temp.decls/temp.class/temp.static/p1-inst.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // Test instantiation of static data members declared out-of-line. @@ -8,13 +8,13 @@ struct X { }; template<typename T> - T X<T>::value = 17; // expected-error{{initialize}} + T X<T>::value = 17; // expected-error{{no viable conversion}} struct InitOkay { InitOkay(int) { } }; -struct CannotInit { }; +struct CannotInit { }; // expected-note{{candidate function}} int &returnInt() { return X<int>::value; } float &returnFloat() { return X<float>::value; } diff --git a/test/CXX/temp/temp.decls/temp.class/temp.static/p1.cpp b/test/CXX/temp/temp.decls/temp.class/temp.static/p1.cpp index 949a8b0a72c7..3cefeb821e99 100644 --- a/test/CXX/temp/temp.decls/temp.class/temp.static/p1.cpp +++ b/test/CXX/temp/temp.decls/temp.class/temp.static/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X0 { @@ -6,18 +6,18 @@ struct X0 { }; template<typename T> -T X0<T>::value = 0; // expected-error{{initialize}} +T X0<T>::value = 0; // expected-error{{no viable conversion}} struct X1 { X1(int); }; -struct X2 { }; +struct X2 { }; // expected-note{{candidate function}} int& get_int() { return X0<int>::value; } X1& get_X1() { return X0<X1>::value; } -double*& get_double_ptr() { return X0<int*>::value; } // expected-error{{initialized}} +double*& get_double_ptr() { return X0<int*>::value; } // expected-error{{non-const lvalue reference to type 'double *' cannot bind to a value of unrelated type 'int *'}} X2& get_X2() { return X0<X2>::value; // expected-note{{instantiation}} diff --git a/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p4.cpp b/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p4.cpp index fe42ba41d81e..b2a6219d04e6 100644 --- a/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p4.cpp +++ b/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p4.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<class T> struct A { A(); }; template<class T> int &f(T); diff --git a/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p5.cpp b/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p5.cpp index 27e4426b9082..4d34968d32aa 100644 --- a/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p5.cpp +++ b/test/CXX/temp/temp.decls/temp.fct/temp.func.order/p5.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<class T> int &f(T); template<class T> float &f(T*, int=1); diff --git a/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4-neg.cpp b/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4-neg.cpp index 399dcc4bed76..e9a3eaa79d67 100644 --- a/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4-neg.cpp +++ b/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4-neg.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> void f0(T) { } // expected-note{{previous}} template<class U> void f0(U) { } // expected-error{{redefinition}} diff --git a/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4.cpp b/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4.cpp index de1a883bcd7a..f42b94a727d2 100644 --- a/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4.cpp +++ b/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p4.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // All of these function templates are distinct. template<typename T> void f0(T) { } diff --git a/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p6.cpp b/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p6.cpp index 2571e45c5cde..a668adafcaf5 100644 --- a/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p6.cpp +++ b/test/CXX/temp/temp.decls/temp.fct/temp.over.link/p6.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<int N, int M> struct A0 { diff --git a/test/CXX/temp/temp.decls/temp.friend/p1.cpp b/test/CXX/temp/temp.decls/temp.friend/p1.cpp index fc392da00acf..7a28e70c9ae6 100644 --- a/test/CXX/temp/temp.decls/temp.friend/p1.cpp +++ b/test/CXX/temp/temp.decls/temp.friend/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -emit-llvm-only %s +// RUN: %clang_cc1 -emit-llvm-only %s template <typename T> struct Num { T value_; diff --git a/test/CXX/temp/temp.decls/temp.friend/p3.cpp b/test/CXX/temp/temp.decls/temp.friend/p3.cpp index 4615bebe711f..17d8c85df00c 100644 --- a/test/CXX/temp/temp.decls/temp.friend/p3.cpp +++ b/test/CXX/temp/temp.decls/temp.friend/p3.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template <class T> class A { typedef int Member; diff --git a/test/CXX/temp/temp.decls/temp.friend/p5.cpp b/test/CXX/temp/temp.decls/temp.friend/p5.cpp index 74895c490623..f23611bd505e 100644 --- a/test/CXX/temp/temp.decls/temp.friend/p5.cpp +++ b/test/CXX/temp/temp.decls/temp.friend/p5.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template <class T> class A { class Member { diff --git a/test/CXX/temp/temp.decls/temp.mem/p1.cpp b/test/CXX/temp/temp.decls/temp.mem/p1.cpp index 80b18467a364..1b9da84886e7 100644 --- a/test/CXX/temp/temp.decls/temp.mem/p1.cpp +++ b/test/CXX/temp/temp.decls/temp.mem/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template <class T> struct A { static T cond; diff --git a/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p1.cpp b/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p1.cpp index 088a9e55eb3e..0aef6adad13f 100644 --- a/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p1.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only %s +// RUN: %clang_cc1 -fsyntax-only %s template<typename T> struct A { }; diff --git a/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p3-nodeduct.cpp b/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p3-nodeduct.cpp new file mode 100644 index 000000000000..a8b83d4854e3 --- /dev/null +++ b/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p3-nodeduct.cpp @@ -0,0 +1,37 @@ +// RUN: %clang_cc1 -fsyntax-only -verify %s + +// PR5811 +template <class F> void Call(F f) { f(1); } +template <typename T> void f(T); +void a() { Call(f<int>); } + +// Check the conversion of a template-id to a pointer +template<typename T, T* Address> struct Constant { }; +Constant<void(int), &f<int> > constant0; + +template<typename T, T* Address> void constant_func(); +void test_constant_func() { + constant_func<void(int), &f<int> >(); +} + + +// Check typeof() on a template-id referring to a single function +template<typename T, typename U> +struct is_same { + static const bool value = false; +}; + +template<typename T> +struct is_same<T, T> { + static const bool value = true; +}; + +int typeof0[is_same<__typeof__(f<int>), void (int)>::value? 1 : -1]; +int typeof1[is_same<__typeof__(&f<int>), void (*)(int)>::value? 1 : -1]; + +template <typename T> void g(T); +template <typename T> void g(T, T); + +int typeof2[is_same<__typeof__(g<float>), void (int)>::value? 1 : -1]; // \ + // expected-error{{cannot determine the type of an overloaded function}} \ + // FIXME: expected-error{{use of undeclared identifier}} diff --git a/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p3.cpp b/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p3.cpp index 01030b2a8a20..2530f128a49d 100644 --- a/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p3.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.arg.explicit/p3.cpp @@ -1,6 +1,6 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s -template<class X, class Y, class Z> X f(Y,Z); +template<class X, class Y, class Z> X f(Y,Z); // expected-note {{candidate function}} void g() { f<int,char*,double>("aa",3.0); diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/sfinae-1.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/sfinae-1.cpp index d193fb2ef296..f6121b373e13 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/sfinae-1.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/sfinae-1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc %s +// RUN: %clang_cc1 %s typedef char one_byte; struct two_bytes { char data[2]; }; diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/basic.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/basic.cpp index beb6aad2c089..bcfb71c987eb 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/basic.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/basic.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct A { }; @@ -15,7 +15,7 @@ void test_f1(int *ip, float fv) { f1(ip, fv); } -template<typename T> void f2(T*, T*); +template<typename T> void f2(T*, T*); // expected-note 2 {{candidate function}} struct ConvToIntPtr { operator int*() const; diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p2.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p2.cpp index 6f27d3636892..c165c4530668 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p2.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p2.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct A { }; // bullet 1 diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp index dbe2ff3e18fb..9fefbe1b0368 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.call/p3.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct A { }; diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p2.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p2.cpp index 7d175781c2d9..5a9ea084fd61 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p2.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p2.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // FIXME: [temp.deduct.conv]p2 bullets 1 and 2 can't actually happen without // references? diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p3.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p3.cpp index 95bd7fe12159..e23e98abe64d 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p3.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p3.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s struct AnyPtr { template<typename T> operator T*() const; diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p4.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p4.cpp index 50d31fb2f851..4dca820c1929 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p4.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.conv/p4.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only %s +// RUN: %clang_cc1 -fsyntax-only %s struct AnyT { template<typename T> diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.funcaddr/p1.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.funcaddr/p1.cpp index 86a34500ad41..99a265af394c 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.funcaddr/p1.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.funcaddr/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only %s +// RUN: %clang_cc1 -fsyntax-only %s template<typename T> T f0(T, int); diff --git a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.partial/p11.cpp b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.partial/p11.cpp index 072789c7d579..99ade4bc9974 100644 --- a/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.partial/p11.cpp +++ b/test/CXX/temp/temp.fct.spec/temp.deduct/temp.deduct.partial/p11.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template <class T> T* f(int); // #1 template <class T, class U> T& f(U); // #2 diff --git a/test/CXX/temp/temp.param/p10.cpp b/test/CXX/temp/temp.param/p10.cpp index 56e7f3281eb6..b9dac75beb91 100644 --- a/test/CXX/temp/temp.param/p10.cpp +++ b/test/CXX/temp/temp.param/p10.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename> struct Y1; template<typename, int> struct Y2; diff --git a/test/CXX/temp/temp.param/p11.cpp b/test/CXX/temp/temp.param/p11.cpp index 9e7fd39c0a46..5af0c4e91b56 100644 --- a/test/CXX/temp/temp.param/p11.cpp +++ b/test/CXX/temp/temp.param/p11.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename> struct Y1; template<typename, int> struct Y2; diff --git a/test/CXX/temp/temp.param/p12.cpp b/test/CXX/temp/temp.param/p12.cpp index 3864fbeaa11e..7be38790905f 100644 --- a/test/CXX/temp/temp.param/p12.cpp +++ b/test/CXX/temp/temp.param/p12.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename> struct Y1; // expected-note{{too few template parameters in template template argument}} template<typename, int> struct Y2; diff --git a/test/CXX/temp/temp.param/p13.cpp b/test/CXX/temp/temp.param/p13.cpp index 559b892d0fd2..7e7dbe58a7b5 100644 --- a/test/CXX/temp/temp.param/p13.cpp +++ b/test/CXX/temp/temp.param/p13.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // The scope of atemplate-parameterextends from its point of // declaration until the end of its template. In particular, a diff --git a/test/CXX/temp/temp.param/p14.cpp b/test/CXX/temp/temp.param/p14.cpp index 150e0ad636be..a6c53c1e64a6 100644 --- a/test/CXX/temp/temp.param/p14.cpp +++ b/test/CXX/temp/temp.param/p14.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // XFAIL: * // A template-parameter shall not be used in its own default argument. diff --git a/test/CXX/temp/temp.param/p15-cxx0x.cpp b/test/CXX/temp/temp.param/p15-cxx0x.cpp index 57b6ee22410c..0ce669979c11 100644 --- a/test/CXX/temp/temp.param/p15-cxx0x.cpp +++ b/test/CXX/temp/temp.param/p15-cxx0x.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -std=c++0x -verify %s +// RUN: %clang_cc1 -fsyntax-only -std=c++0x -verify %s template<typename T> struct X; template<int I> struct Y; diff --git a/test/CXX/temp/temp.param/p15.cpp b/test/CXX/temp/temp.param/p15.cpp index 764bb7bae073..13087791a3db 100644 --- a/test/CXX/temp/temp.param/p15.cpp +++ b/test/CXX/temp/temp.param/p15.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -std=c++98 -verify %s +// RUN: %clang_cc1 -fsyntax-only -std=c++98 -verify %s template<typename T> struct X; template<int I> struct Y; diff --git a/test/CXX/temp/temp.param/p2.cpp b/test/CXX/temp/temp.param/p2.cpp index d40f99b58a29..41868c5c1ac7 100644 --- a/test/CXX/temp/temp.param/p2.cpp +++ b/test/CXX/temp/temp.param/p2.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // There is no semantic difference between class and typename in a // template-parameter. typename followed by an unqualified-id names a diff --git a/test/CXX/temp/temp.param/p3.cpp b/test/CXX/temp/temp.param/p3.cpp index 6a76fe20b81a..67d648ea97bb 100644 --- a/test/CXX/temp/temp.param/p3.cpp +++ b/test/CXX/temp/temp.param/p3.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // A type-parameter defines its identifier to be a type-name (if // declared with class or typename) or template-name (if declared with @@ -15,7 +15,7 @@ template<template<class T> class Y> struct X1 { // could be interpreted as either a non-type template-parameter or a // type-parameter (because its identifier is the name of an already // existing class) is taken as a type-parameter. For example, -class T { /* ... */ }; +class T { /* ... */ }; // expected-note{{candidate function}} int i; template<class T, T i> struct X2 { @@ -23,6 +23,6 @@ template<class T, T i> struct X2 { { T t1 = i; //template-parameters T and i ::T t2 = ::i; // global namespace members T and i \ - // expected-error{{cannot initialize}} + // expected-error{{no viable conversion}} } }; diff --git a/test/CXX/temp/temp.param/p4.cpp b/test/CXX/temp/temp.param/p4.cpp index 3efff1243600..5ec402a45bf5 100644 --- a/test/CXX/temp/temp.param/p4.cpp +++ b/test/CXX/temp/temp.param/p4.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s class X; // C++ [temp.param]p4 diff --git a/test/CXX/temp/temp.param/p7.cpp b/test/CXX/temp/temp.param/p7.cpp index ccc869ae0fbe..13f0367764aa 100644 --- a/test/CXX/temp/temp.param/p7.cpp +++ b/test/CXX/temp/temp.param/p7.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // A non-type template-parameter shall not be declared to have // floating point, class, or void type. diff --git a/test/CXX/temp/temp.param/p8.cpp b/test/CXX/temp/temp.param/p8.cpp index dd4af17d79fa..fed048cad8b6 100644 --- a/test/CXX/temp/temp.param/p8.cpp +++ b/test/CXX/temp/temp.param/p8.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<int X[10]> struct A; template<int *X> struct A; template<int f(float, double)> struct B; diff --git a/test/CXX/temp/temp.param/p9.cpp b/test/CXX/temp/temp.param/p9.cpp index d6b740544d02..625477c4e7b6 100644 --- a/test/CXX/temp/temp.param/p9.cpp +++ b/test/CXX/temp/temp.param/p9.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -std=c++98 -verify %s +// RUN: %clang_cc1 -fsyntax-only -std=c++98 -verify %s // A default template-argument shall not be specified in a function // template declaration or a function template definition diff --git a/test/CXX/temp/temp.res/temp.dep.res/temp.point/p1.cpp b/test/CXX/temp/temp.res/temp.dep.res/temp.point/p1.cpp index a41b46ff5c9b..75580d245cfc 100644 --- a/test/CXX/temp/temp.res/temp.dep.res/temp.point/p1.cpp +++ b/test/CXX/temp/temp.res/temp.dep.res/temp.point/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // XFAIL: * // Note: we fail this test because we perform template instantiation diff --git a/test/CXX/temp/temp.res/temp.dep/p3.cpp b/test/CXX/temp/temp.res/temp.dep/p3.cpp index d47f0d683514..c41a4c60ee74 100644 --- a/test/CXX/temp/temp.res/temp.dep/p3.cpp +++ b/test/CXX/temp/temp.res/temp.dep/p3.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s struct A0 { struct K { }; }; diff --git a/test/CXX/temp/temp.spec/p5.cpp b/test/CXX/temp/temp.spec/p5.cpp index d5632e7f341d..c37817cc49b8 100644 --- a/test/CXX/temp/temp.spec/p5.cpp +++ b/test/CXX/temp/temp.spec/p5.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> inline void f(T) { } template void f(int); // expected-note{{previous explicit instantiation}} diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p1.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p1.cpp index 239b8aeb04e4..3843c0d2c880 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p1.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // This test creates cases where implicit instantiations of various entities // would cause a diagnostic, but provides expliict specializations for those diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p10.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p10.cpp index 61f1710a6b9e..b81c1e7b2c8f 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p10.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p10.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<class T> class X; template<> class X<int>; // expected-note{{forward}} diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p11.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p11.cpp index e794e67a5ef3..5fa2f627b009 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p11.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p11.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<class T> class Array { /* ... */ }; template<class T> void sort(Array<T>& v); diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p13.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p13.cpp index 63cf9f5e50d1..fb6d1bed1f71 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p13.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p13.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only %s +// RUN: %clang_cc1 -fsyntax-only %s template<typename T> void f(T); diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p14.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p14.cpp index a5d5b9e3c41e..121cb8eedf2f 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p14.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p14.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -emit-llvm -o - %s | FileCheck %s +// RUN: %clang_cc1 -emit-llvm -o - %s | FileCheck %s template<class T> void f(T) { /* ... */ } template<class T> inline void g(T) { /* ... */ } diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p15.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p15.cpp index 840f566362ed..6e7f80842ec0 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p15.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p15.cpp @@ -1,7 +1,7 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s struct NonDefaultConstructible { - NonDefaultConstructible(const NonDefaultConstructible&); + NonDefaultConstructible(const NonDefaultConstructible&); // expected-note{{candidate function}} }; template<typename T, typename U> diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p16.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p16.cpp index ce40afd40225..2f9a3cbf9457 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p16.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p16.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only %s +// RUN: %clang_cc1 -fsyntax-only %s template<class T> struct A { void f(T); template<class X1> void g1(T, X1); diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p17.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p17.cpp index 06653044c3bb..3b5b5afa8ed9 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p17.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p17.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<class T1> class A { template<class T2> class B { diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p18.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p18.cpp index a5877d281d74..4d175a886087 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p18.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p18.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<class T1> class A { template<class T2> class B { template<class T3> void mf1(T3); diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p19.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p19.cpp index 1f38e5a2c17d..1c2ea7ebde71 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p19.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p19.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X { diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p2.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p2.cpp index 64856605a0a7..654f5abb8a54 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p2.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p2.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // This test creates cases where implicit instantiations of various entities // would cause a diagnostic, but provides expliict specializations for those diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p20.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p20.cpp index d270b8167a16..f987c120a2de 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p20.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p20.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> void f(T); diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p21.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p21.cpp index 9dae3eb5190b..ab26f407f3f3 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p21.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p21.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X { diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p3.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p3.cpp index de05a926338c..84841cb60f4d 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p3.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p3.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s namespace N { template<class T> class X; diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p4.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p4.cpp index ad0d50621367..3eaf89689a25 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p4.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p4.cpp @@ -1,7 +1,7 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s -struct IntHolder { // expected-note{{here}} - IntHolder(int); +struct IntHolder { // expected-note{{here}} // expected-note 2{{candidate function}} + IntHolder(int); // expected-note 2{{candidate function}} }; template<typename T, typename U> diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p5.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p5.cpp index 58682c786f95..512ea47d5a5f 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p5.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p5.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s struct IntHolder { IntHolder(int); diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p6.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p6.cpp index e92d3f0a8883..34c3710e04c5 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p6.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p6.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X0 { diff --git a/test/CXX/temp/temp.spec/temp.expl.spec/p9.cpp b/test/CXX/temp/temp.spec/temp.expl.spec/p9.cpp index 49481d2e6d7a..d4ce01fd6501 100644 --- a/test/CXX/temp/temp.spec/temp.expl.spec/p9.cpp +++ b/test/CXX/temp/temp.spec/temp.expl.spec/p9.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s namespace N { template<class T> class X { /* ... */ }; diff --git a/test/CXX/temp/temp.spec/temp.explicit/p1-0x.cpp b/test/CXX/temp/temp.spec/temp.explicit/p1-0x.cpp index d7731f17637c..a4caceae4954 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p1-0x.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p1-0x.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -std=c++0x -verify %s +// RUN: %clang_cc1 -fsyntax-only -std=c++0x -verify %s template<typename T> struct X { diff --git a/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp b/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp index 3938509961b4..70eb69641867 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p1-emit.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -emit-llvm -triple x86_64-apple-darwin10 -o - %s | FileCheck %s +// RUN: %clang_cc1 -emit-llvm -triple x86_64-apple-darwin10 -o - %s | FileCheck %s template<typename T> struct X { static T member1; diff --git a/test/CXX/temp/temp.spec/temp.explicit/p1.cpp b/test/CXX/temp/temp.spec/temp.explicit/p1.cpp index 896e30efb886..626bdf181503 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p1.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p1.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s struct C { }; @@ -14,7 +14,7 @@ template struct X0<void>; // expected-note{{instantiation}} // Explicitly instantiate a function template specialization template<typename T> void f0(T t) { - ++t; // expected-error{{cannot modify}} + ++t; // expected-error{{cannot increment}} } template void f0(int); @@ -48,8 +48,8 @@ template void X1<int>::f<>(int&, int*); // expected-note{{instantiation}} // Explicitly instantiate members of a class template struct Incomplete; // expected-note{{forward declaration}} -struct NonDefaultConstructible { - NonDefaultConstructible(int); +struct NonDefaultConstructible { // expected-note{{candidate function}} + NonDefaultConstructible(int); // expected-note{{candidate function}} }; template<typename T, typename U> @@ -68,7 +68,7 @@ struct X2 { }; template<typename T, typename U> -T X2<T, U>::static_member1 = 17; // expected-error{{incompatible type}} +T X2<T, U>::static_member1 = 17; // expected-error{{cannot initialize}} template<typename T, typename U> U X2<T, U>::static_member2; // expected-error{{no matching}} diff --git a/test/CXX/temp/temp.spec/temp.explicit/p10.cpp b/test/CXX/temp/temp.spec/temp.explicit/p10.cpp index 900b0b309277..290a874296e1 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p10.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p10.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X0 { @@ -20,7 +20,7 @@ struct X0<T>::Inner { }; template<typename T> -T X0<T>::static_var = 1; // expected-error{{incompatible type}} +T X0<T>::static_var = 1; // expected-error{{cannot initialize}} extern template struct X0<void*>; template struct X0<void*>; // expected-note 2{{instantiation}} diff --git a/test/CXX/temp/temp.spec/temp.explicit/p12.cpp b/test/CXX/temp/temp.spec/temp.explicit/p12.cpp index fdf4393d4385..912b8e17bb98 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p12.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p12.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s char* p = 0; template<class T> T g(T x = &p) { return x; } diff --git a/test/CXX/temp/temp.spec/temp.explicit/p2.cpp b/test/CXX/temp/temp.spec/temp.explicit/p2.cpp index f3d2c955cb5b..8538d27f09bc 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p2.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p2.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // Example from the standard template<class T> class Array { void mf() { } }; diff --git a/test/CXX/temp/temp.spec/temp.explicit/p3.cpp b/test/CXX/temp/temp.spec/temp.explicit/p3.cpp index 9057971a5bb4..e30f046c2bd1 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p3.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p3.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s // A declaration of a function template shall be in scope at the point of the // explicit instantiation of the function template. @@ -8,14 +8,12 @@ template void f0(int); // okay // A definition of the class or class template containing a member function // template shall be in scope at the point of the explicit instantiation of // the member function template. -struct X0; // expected-note 2{{forward declaration}} -template<typename> struct X1; // expected-note 5{{declared here}} +struct X0; // expected-note 3{{forward declaration}} +template<typename> struct X1; // expected-note 8{{declared here}} // FIXME: Repeated diagnostics here! -template void X0::f0<int>(int); // expected-error 2{{incomplete type}} \ - // expected-error{{does not refer}} -template void X1<int>::f0<int>(int); // expected-error 2{{implicit instantiation of undefined template}} \ - // expected-error{{does not refer}} +template void X0::f0<int>(int); // expected-error 3{{incomplete type}} // expected-error{{invalid token after top level declarator}} +template void X1<int>::f0<int>(int); // expected-error 3{{implicit instantiation of undefined template}} // expected-error{{invalid token after top level declarator}} // A definition of a class template or class member template shall be in scope // at the point of the explicit instantiation of the class template or class @@ -35,10 +33,10 @@ template struct X2<int>::Inner<float>; // expected-error{{explicit instantiation // A definition of a class template shall be in scope at the point of an // explicit instantiation of a member function or a static data member of the // class template. -template void X1<int>::f1(int); // expected-error{{undefined template}} \ +template void X1<int>::f1(int); // expected-error 2{{undefined template}} \ // expected-error{{does not refer}} -template int X1<int>::member; // expected-error{{undefined template}} \ +template int X1<int>::member; // expected-error 2{{undefined template}} \ // expected-error{{does not refer}} // A definition of a member class of a class template shall be in scope at the diff --git a/test/CXX/temp/temp.spec/temp.explicit/p4.cpp b/test/CXX/temp/temp.spec/temp.explicit/p4.cpp index 04e511b0b2d5..f292b5a93d38 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p4.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p4.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> void f0(T); // expected-note{{here}} template void f0(int); // expected-error{{explicit instantiation of undefined function template}} diff --git a/test/CXX/temp/temp.spec/temp.explicit/p5.cpp b/test/CXX/temp/temp.spec/temp.explicit/p5.cpp index a992648d7c48..13fb0492f1a4 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p5.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p5.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s namespace N { template<class T> class Y { // expected-note{{explicit instantiation refers here}} diff --git a/test/CXX/temp/temp.spec/temp.explicit/p6.cpp b/test/CXX/temp/temp.spec/temp.explicit/p6.cpp index 763d679db7bb..44ce41b6f957 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p6.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p6.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<class T> class Array { /* ... */ }; template<class T> void sort(Array<T>& v) { } diff --git a/test/CXX/temp/temp.spec/temp.explicit/p7.cpp b/test/CXX/temp/temp.spec/temp.explicit/p7.cpp index ffd653dbaa4f..b62e0cb9b1cd 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p7.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p7.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X0 { diff --git a/test/CXX/temp/temp.spec/temp.explicit/p8.cpp b/test/CXX/temp/temp.spec/temp.explicit/p8.cpp index 9a5bd3245c78..0c5aec3b0bc8 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p8.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p8.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -verify %s +// RUN: %clang_cc1 -fsyntax-only -verify %s template<typename T> struct X0 { diff --git a/test/CXX/temp/temp.spec/temp.explicit/p9-linkage.cpp b/test/CXX/temp/temp.spec/temp.explicit/p9-linkage.cpp index 59705d8a20e7..e67233c37547 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p9-linkage.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p9-linkage.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -emit-llvm -std=c++0x -o - %s | FileCheck %s +// RUN: %clang_cc1 -emit-llvm -std=c++0x -o - %s | FileCheck %s template<typename T> struct X0 { diff --git a/test/CXX/temp/temp.spec/temp.explicit/p9.cpp b/test/CXX/temp/temp.spec/temp.explicit/p9.cpp index a53113fb969e..ad973bb7c589 100644 --- a/test/CXX/temp/temp.spec/temp.explicit/p9.cpp +++ b/test/CXX/temp/temp.spec/temp.explicit/p9.cpp @@ -1,4 +1,4 @@ -// RUN: clang-cc -fsyntax-only -std=c++0x -verify %s +// RUN: %clang_cc1 -fsyntax-only -std=c++0x -verify %s template<typename T> struct X0 { |