From 0209f562837691b5d5aefb775f0c571d9e7283da Mon Sep 17 00:00:00 2001 From: Hans Wennborg Date: Fri, 13 Dec 2013 18:34:23 +0000 Subject: 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 --- test/SemaTemplate/explicit-instantiation.cpp | 2 +- test/SemaTemplate/instantiate-method.cpp | 2 +- test/SemaTemplate/temp_arg_nontype.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'test/SemaTemplate') 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 T f0(T, U) { return T(); } // expected-note-re {{candidate template ignored: could not match 'int (int, U){{.*}}' against 'int (int) {{.*}}const'}} \ + template 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 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 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 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 struct A7; // expected-note{{template parameter is declared here}} -- cgit v1.2.3