r214847 - MS ABI: Make the alias template mangling more correct

David Majnemer david.majnemer at gmail.com
Mon Aug 4 23:42:40 PDT 2014


Author: majnemer
Date: Tue Aug  5 01:42:40 2014
New Revision: 214847

URL: http://llvm.org/viewvc/llvm-project?rev=214847&view=rev
Log:
MS ABI: Make the alias template mangling more correct

Modified:
    cfe/trunk/lib/AST/MicrosoftMangle.cpp
    cfe/trunk/test/CodeGenCXX/mangle-ms-cxx11.cpp

Modified: cfe/trunk/lib/AST/MicrosoftMangle.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/MicrosoftMangle.cpp?rev=214847&r1=214846&r2=214847&view=diff
==============================================================================
--- cfe/trunk/lib/AST/MicrosoftMangle.cpp (original)
+++ cfe/trunk/lib/AST/MicrosoftMangle.cpp Tue Aug  5 01:42:40 2014
@@ -1187,7 +1187,7 @@ void MicrosoftCXXNameMangler::mangleTemp
     } else if (isa<TypeAliasDecl>(ND)) {
       // FIXME: The mangling, while compatible with VS "14", is horribly
       // broken.  Update this when they release their next compiler.
-      Out << '?';
+      Out << '$';
     } else {
       llvm_unreachable("unexpected template template NamedDecl!");
     }

Modified: cfe/trunk/test/CodeGenCXX/mangle-ms-cxx11.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGenCXX/mangle-ms-cxx11.cpp?rev=214847&r1=214846&r2=214847&view=diff
==============================================================================
--- cfe/trunk/test/CodeGenCXX/mangle-ms-cxx11.cpp (original)
+++ cfe/trunk/test/CodeGenCXX/mangle-ms-cxx11.cpp Tue Aug  5 01:42:40 2014
@@ -151,5 +151,5 @@ template <template <typename> class>
 void f() {}
 
 template void f<AliasA>();
-// CHECK-DAG: @"\01??$f@?@PR20047@@YAXXZ"
+// CHECK-DAG: @"\01??$f@$@PR20047@@YAXXZ"
 }





More information about the cfe-commits mailing list