From 53992adde3eda3ccf9da63bc7e45673f043de18f Mon Sep 17 00:00:00 2001 From: rdivacky Date: Thu, 27 May 2010 15:17:06 +0000 Subject: Update clang to r104832. --- test/SemaTemplate/instantiate-non-dependent-types.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 test/SemaTemplate/instantiate-non-dependent-types.cpp (limited to 'test/SemaTemplate/instantiate-non-dependent-types.cpp') diff --git a/test/SemaTemplate/instantiate-non-dependent-types.cpp b/test/SemaTemplate/instantiate-non-dependent-types.cpp new file mode 100644 index 0000000..a0005c5 --- /dev/null +++ b/test/SemaTemplate/instantiate-non-dependent-types.cpp @@ -0,0 +1,14 @@ +// RUN: %clang_cc1 -fsyntax-only -verify %s +template +struct X1 { + static void member() { T* x = 1; } // expected-error{{cannot initialize a variable of type 'int *' with an rvalue of type 'int'}} +}; + +template struct instantiate { }; + +template +struct X2 { + typedef instantiate<&X1::member> i; // expected-note{{in instantiation of}} +}; + +X2 x; -- cgit v1.1