diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2011-02-21 20:10:02 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2011-02-21 20:10:02 +0000 |
commit | 967ecd3bed2b7f6ea04a1592dced6fc5d44d0b5d (patch) | |
tree | 5a9c938754e5f3cbe9caf6117429d058a65447ca /test/CodeGenCXX/mangle-exprs.cpp | |
parent | 483b9f3bc05c5409e2c6643f1c9d91e21c8ff9d2 (diff) |
Mangling of undeduced 'auto' types, as specified by Itanium C++ ABI.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126140 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/mangle-exprs.cpp')
-rw-r--r-- | test/CodeGenCXX/mangle-exprs.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/test/CodeGenCXX/mangle-exprs.cpp b/test/CodeGenCXX/mangle-exprs.cpp index 7322171856..e5f26e584b 100644 --- a/test/CodeGenCXX/mangle-exprs.cpp +++ b/test/CodeGenCXX/mangle-exprs.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -emit-llvm %s -o - -triple=x86_64-apple-darwin9 | FileCheck %s +// RUN: %clang_cc1 -std=c++0x -emit-llvm %s -o - -triple=x86_64-apple-darwin9 | FileCheck %s template < bool condition, typename T = void > struct enable_if { typedef T type; }; @@ -24,6 +24,10 @@ namespace Casts { void static_(typename enable_if< O <= static_cast<unsigned>(4) >::type* = 0) { } + template< typename T > + void auto_(decltype(new auto(T()))) { + } + // FIXME: Test const_cast, reinterpret_cast, dynamic_cast, which are // a bit harder to use in template arguments. template <unsigned N> struct T {}; @@ -41,4 +45,7 @@ namespace Casts { // CHECK: define weak_odr void @_ZN5Casts1fILi6EEENS_1TIXT_EEEv template T<6> f<6>(); + + // CHECK: define weak_odr void @_ZN5Casts5auto_IiEEvDTnw_DapicvT__EEE( + template void auto_<int>(int*); } |