diff options
Diffstat (limited to 'test/Misc/diag-template-diffing-cxx98.cpp')
-rw-r--r-- | test/Misc/diag-template-diffing-cxx98.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/test/Misc/diag-template-diffing-cxx98.cpp b/test/Misc/diag-template-diffing-cxx98.cpp index cd40ccc374..f374fbc417 100644 --- a/test/Misc/diag-template-diffing-cxx98.cpp +++ b/test/Misc/diag-template-diffing-cxx98.cpp @@ -4,4 +4,14 @@ namespace PR14342 { template<typename T, char a> struct X {}; X<int, 1> x = X<long, 257>(); // CHECK: error: no viable conversion from 'X<long, [...]>' to 'X<int, [...]>' -}
\ No newline at end of file +} + +namespace PR15513 { + template <int x, int y = x+1> + class A {}; + + void foo(A<0> &M) { + // CHECK: no viable conversion from 'A<[...], (default) x + 1>' to 'A<[...], 0>' + A<0, 0> N = M; + } +} |