From 29805ca6d278b4d9563adfee67f2478f0fecdcfc Mon Sep 17 00:00:00 2001 From: Richard Smith Date: Thu, 31 Jan 2013 05:19:49 +0000 Subject: Improve 'failed template argument deduction' diagnostic for the case where we have a direct mismatch between some component of the template and some component of the argument. The diagnostic now says what the mismatch was, but doesn't yet say which part of the template doesn't match. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174039 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/SemaCXX/c99-variable-length-array.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test/SemaCXX/c99-variable-length-array.cpp') diff --git a/test/SemaCXX/c99-variable-length-array.cpp b/test/SemaCXX/c99-variable-length-array.cpp index de9c11e565..bb620c71fa 100644 --- a/test/SemaCXX/c99-variable-length-array.cpp +++ b/test/SemaCXX/c99-variable-length-array.cpp @@ -64,8 +64,9 @@ X1 x1a; X1 x1b; // expected-note{{in instantiation of}} // Template argument deduction does not allow deducing a size from a VLA. +// FIXME: This diagnostic should make it clear that the two 'N's are different entities! template -void accept_array(T (&array)[N]); // expected-note{{candidate template ignored: failed template argument deduction}} +void accept_array(T (&array)[N]); // expected-note{{candidate template ignored: could not match 'T [N]' against 'int [N]'}} void test_accept_array(int N) { int array[N]; // expected-warning{{variable length arrays are a C99 feature}} -- cgit v1.2.3-18-g5258