diff options
author | Richard Trieu <rtrieu@google.com> | 2013-01-31 02:47:46 +0000 |
---|---|---|
committer | Richard Trieu <rtrieu@google.com> | 2013-01-31 02:47:46 +0000 |
commit | f499b34d4911dda3b20ede1377ea29b83d3f149e (patch) | |
tree | 31af065ce15ee1a319cd0d2e0a757be971b419c6 /test/Misc/diag-template-diffing.cpp | |
parent | 95f97bf07a1811d020cbdcaa51d6e25752a4bd37 (diff) |
When comparing two template template arguments in the template differ, consider
them the same if they are actually the same; having the same name isn't enough.
Similar to r174013, template template arguments were also mistakenly considered
the same when they had the same name but were in different namespaces.
In addition, when printing template template arguments, use the qualified name
if the regular name is the same.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174029 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Misc/diag-template-diffing.cpp')
-rw-r--r-- | test/Misc/diag-template-diffing.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/Misc/diag-template-diffing.cpp b/test/Misc/diag-template-diffing.cpp index 7e9998c828..c6fc32d1b3 100644 --- a/test/Misc/diag-template-diffing.cpp +++ b/test/Misc/diag-template-diffing.cpp @@ -859,6 +859,14 @@ namespace rdar12931988 { // CHECK-ELIDE-NOTREE: no known conversion from 'B::X<int>' to 'const rdar12931988::A::X<int>' ax = bx; } + + template<template<typename> class> class Y {}; + + void bar(Y<A::X> ya, Y<B::X> yb) { + // CHECK-ELIDE-NOTREE: no viable overloaded '=' + // CHECK-ELIDE-NOTREE: no known conversion from 'Y<template rdar12931988::B::X>' to 'Y<template rdar12931988::A::X>' + ya = yb; + } } // CHECK-ELIDE-NOTREE: {{[0-9]*}} errors generated. |