From: Timur Iskhodzhanov Date: Wed, 27 Jun 2012 21:53:00 +0000 (+0000) Subject: Two more tests for PR13207 - wrong mangling of templates with back references [-cxx... X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8771872ab78fe4bd65393f94f2b1b6eb8b4ec6d3;p=clang Two more tests for PR13207 - wrong mangling of templates with back references [-cxx-abi microsoft] git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159296 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/CodeGenCXX/mangle-ms-back-references.cpp b/test/CodeGenCXX/mangle-ms-back-references.cpp index 73e4d5c192..33a442259c 100644 --- a/test/CodeGenCXX/mangle-ms-back-references.cpp +++ b/test/CodeGenCXX/mangle-ms-back-references.cpp @@ -73,6 +73,8 @@ class A {}; class B {}; class C {}; +template +class F {}; template class I {}; template @@ -97,6 +99,18 @@ void bar(J x) {} void spam(K x) {} // CHECK: "\01?spam@PR13207@@YAXV?$K@VA@PR13207@@VB@2@VC@2@@1@@Z" +// The following CURRENT line is here to improve the precision of the "scanning +// from here" reports of FileCheck. +// CURRENT: "\01?spam@PR13207@@YAXV?$K@VA@PR13207@@VB@2@VC@2@@1@@Z" + +// The tests below currently fail: +void baz(K, I >) {} +// CURRENT: "\01?baz@PR13207@@YAXV?$K@DV?$F@D@PR13207@@V?$I@D@1@@1@@Z" +// CORRECT: "\01?baz@PR13207@@YAXV?$K@DV?$F@D@PR13207@@V?$I@D@2@@1@@Z" +void qux(K, I >) {} +// CURRENT: "\01?qux@PR13207@@YAXV?$K@DV?$I@D@PR13207@@V?$I@D@1@@1@@Z" +// CORRECT: "\01?qux@PR13207@@YAXV?$K@DV?$I@D@PR13207@@V12@@1@@Z + namespace NA { class X {}; template class Y {}; @@ -116,10 +130,6 @@ void bar(NA::Y x) {} void spam(NA::Y x) {} // CHECK: "\01?spam@NB@PR13207@@YAXV?$Y@VX@NA@PR13207@@@NA@2@@Z" -// The following CURRENT line is here to improve the precision of the "scanning -// from here" reports of FileCheck. -// CURRENT: "\01?spam@NB@PR13207@@YAXV?$Y@VX@NA@PR13207@@@NA@2@@Z" - // The tests below currently fail: void foobar(NA::Y > a, Y >) {} // CURRENT: "\01?foobar@NB@PR13207@@YAXV?$Y@V?$Y@VX@NB@PR13207@@@NB@PR13207@@@NA@2@V?$Y@V?$Y@VX@NB@PR13207@@@NB@PR13207@@@12@@Z"