Do not assume the template argument is an integer only because the
expressions are integer. It can also be ValueDecl expressions
Use the type information from the TemplateParameterList instead
Patch by Olivier Goffart!
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178611 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Misc/diag-template-diffing.cpp b/test/Misc/diag-template-diffing.cpp
index f27f8b6..add96ef 100644
--- a/test/Misc/diag-template-diffing.cpp
+++ b/test/Misc/diag-template-diffing.cpp
@@ -985,6 +985,11 @@
// CHECK-ELIDE-NOTREE: no viable overloaded '='
// CHECK-ELIDE-NOTREE: no known conversion from 'B<(default) i1, (no argument)>' to 'B<i2, i3>'
+ B<i1, i2, i3> b4 = b1;
+ // CHECK-ELIDE-NOTREE: no viable conversion from 'B<[...], (no argument), (no argument)>' to 'B<[...], i2, i3>'
+ B<i2, i3> b5 = b1;
+ // CHECK-ELIDE-NOTREE: no viable conversion from 'B<(default) i1, (no argument)>' to 'B<i2, i3>'
+
C<> c1;
C<void, void> c2;
C<char, char> c3;