diff options
author | Hans Wennborg <hans@hanshq.net> | 2013-12-13 18:34:23 +0000 |
---|---|---|
committer | Hans Wennborg <hans@hanshq.net> | 2013-12-13 18:34:23 +0000 |
commit | 0209f562837691b5d5aefb775f0c571d9e7283da (patch) | |
tree | 5f66c7e67afc3ae2746ad69515a6870adf0033db /test/SemaTemplate | |
parent | 665c732fb4e8d24228f0ff0dc19415eb9e61147f (diff) | |
download | clang-0209f562837691b5d5aefb775f0c571d9e7283da.tar.gz clang-0209f562837691b5d5aefb775f0c571d9e7283da.tar.bz2 clang-0209f562837691b5d5aefb775f0c571d9e7283da.tar.xz |
Tighten test regexes checking for __attribute__((thiscall)) on function types.
The tests were perhaps made too relaxed in r197164 when we switched to the new
MinGW ABI. This makes sure we check explicitly for an optional thiscall
attribute and nothing else.
We should still look into whether we should print these attributes at all in
these cases.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@197252 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaTemplate')
-rw-r--r-- | test/SemaTemplate/explicit-instantiation.cpp | 2 | ||||
-rw-r--r-- | test/SemaTemplate/instantiate-method.cpp | 2 | ||||
-rw-r--r-- | test/SemaTemplate/temp_arg_nontype.cpp | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/test/SemaTemplate/explicit-instantiation.cpp b/test/SemaTemplate/explicit-instantiation.cpp index 5748f662dc..c28c5d1831 100644 --- a/test/SemaTemplate/explicit-instantiation.cpp +++ b/test/SemaTemplate/explicit-instantiation.cpp @@ -16,7 +16,7 @@ struct X0 { } T* f0(T*, T*) { return T(); } // expected-warning{{expression which evaluates to zero treated as a null pointer constant of type 'int *'}} - template <typename U> T f0(T, U) { return T(); } // expected-note-re {{candidate template ignored: could not match 'int (int, U){{.*}}' against 'int (int) {{.*}}const'}} \ + template <typename U> T f0(T, U) { return T(); } // expected-note-re {{candidate template ignored: could not match 'int (int, U){{( __attribute__\(\(thiscall\)\))?}}' against 'int (int){{( __attribute__\(\(thiscall\)\))?}} const'}} \ // expected-note {{candidate template ignored: could not match 'int' against 'int *'}} }; diff --git a/test/SemaTemplate/instantiate-method.cpp b/test/SemaTemplate/instantiate-method.cpp index 55b4c6501b..58cb897955 100644 --- a/test/SemaTemplate/instantiate-method.cpp +++ b/test/SemaTemplate/instantiate-method.cpp @@ -178,7 +178,7 @@ namespace PR7022 { namespace SameSignatureAfterInstantiation { template<typename T> struct S { void f(T *); // expected-note {{previous}} - void f(const T*); // expected-error-re {{multiple overloads of 'f' instantiate to the same signature 'void (const int *){{.*}}'}} + void f(const T*); // expected-error-re {{multiple overloads of 'f' instantiate to the same signature 'void (const int *){{( __attribute__\(\(thiscall\)\))?}}'}} }; S<const int> s; // expected-note {{instantiation}} } diff --git a/test/SemaTemplate/temp_arg_nontype.cpp b/test/SemaTemplate/temp_arg_nontype.cpp index 2921a055c5..91b0c6e765 100644 --- a/test/SemaTemplate/temp_arg_nontype.cpp +++ b/test/SemaTemplate/temp_arg_nontype.cpp @@ -82,7 +82,7 @@ struct Z { template<int (Z::*pmf)(int)> struct A6; // expected-note{{template parameter is declared here}} A6<&Z::foo> *a17_1; A6<&Z::bar> *a17_2; -A6<&Z::baz> *a17_3; // expected-error-re{{non-type template argument of type 'double (Z::*)(double){{.*}}' cannot be converted to a value of type 'int (Z::*)(int){{.*}}'}} +A6<&Z::baz> *a17_3; // expected-error-re{{non-type template argument of type 'double (Z::*)(double){{( __attribute__\(\(thiscall\)\))?}}' cannot be converted to a value of type 'int (Z::*)(int){{( __attribute__\(\(thiscall\)\))?}}'}} template<int Z::*pm> struct A7; // expected-note{{template parameter is declared here}} |