summaryrefslogtreecommitdiff
path: root/compilerplugins
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2020-11-15 21:51:50 +0100
committerStephan Bergmann <sbergman@redhat.com>2020-11-16 08:36:57 +0100
commit99076b47b72e8ad999bc9bfd2e256842a5d06e1e (patch)
tree6b8ba7e61823eaf3028653252a8a4bd17765bab9 /compilerplugins
parent548d77d0c06f7088dd3eb408797aa1fc1d7eb277 (diff)
Adapt to Clang 12 trunk cosmetic diagnostics changes
<https://github.com/llvm/llvm-project/commit/ e7f3e2103cdb567dda4fd52f81bf4bc07179f5a8> "Suppress printing template arguments that match default template arguments of types by default" caused > error: 'error' diagnostics seen but not expected: > File /home/sbergman/lo/core/compilerplugins/clang/test/makeshared.cxx Line 58: rather use make_shared than constructing from 'typename std::remove_reference<unique_ptr<int> &>::type' (aka 'std::unique_ptr<int>') [loplugin:makeshared] > File /home/sbergman/lo/core/compilerplugins/clang/test/makeshared.cxx Line 60: rather use make_shared than constructing from 'typename std::remove_reference<unique_ptr<int> &>::type' (aka 'std::unique_ptr<int>') [loplugin:makeshared] in compilerplugins/clang/test/makeshared.cxx, and <https://github.com/llvm/ llvm-project/commit/5f12f4ff9078455cad9d4806da01f570553a5bf9> "Suppress printing of inline namespace names in diagnostics by default, except where they are necessary to disambiguate the target" caused > error: 'note' diagnostics seen but not expected: > File /home/sbergman/lo/core/compilerplugins/clang/test/external.cxx Line 133: a function associating 'N::E' is declared here [loplugin:external] > File /home/sbergman/lo/core/compilerplugins/clang/test/external.cxx Line 140: a function associating 'N::E' is declared here [loplugin:external] > File /home/sbergman/lo/core/compilerplugins/clang/test/external.cxx Line 144: a function associating 'N::E' is declared here [loplugin:external] > File /home/sbergman/lo/core/compilerplugins/clang/test/external.cxx Line 167: a function associating 'N::E' is declared here [loplugin:external] > File /home/sbergman/lo/core/compilerplugins/clang/test/external.cxx Line 172: a function associating 'N::E' is declared here [loplugin:external] Change-Id: If1ec798fd9876b5be058c63bcaca3e2a36c0dbb6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105904 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'compilerplugins')
-rw-r--r--compilerplugins/clang/test/external.cxx10
-rw-r--r--compilerplugins/clang/test/makeshared.cxx4
2 files changed, 7 insertions, 7 deletions
diff --git a/compilerplugins/clang/test/external.cxx b/compilerplugins/clang/test/external.cxx
index d0391f0cd612..77bb53c6b250 100644
--- a/compilerplugins/clang/test/external.cxx
+++ b/compilerplugins/clang/test/external.cxx
@@ -129,18 +129,18 @@ enum E : int
}
}
-// expected-note@+1 {{a function associating 'N::I1::E' is declared here [loplugin:external]}}
+// expected-note-re@+1 {{a function associating 'N{{(::I1)?}}::E' is declared here [loplugin:external]}}
static void g(std::vector<E>)
{
// expected-note@+1 {{another declaration is here [loplugin:external]}}
void f(E const*);
}
-// expected-note@+1 {{a function associating 'N::I1::E' is declared here [loplugin:external]}}
+// expected-note-re@+1 {{a function associating 'N{{(::I1)?}}::E' is declared here [loplugin:external]}}
void f(E const*);
extern "C++" {
-// expected-note@+1 {{a function associating 'N::I1::E' is declared here [loplugin:external]}}
+// expected-note-re@+1 {{a function associating 'N{{(::I1)?}}::E' is declared here [loplugin:external]}}
void fc(E const*);
}
@@ -163,12 +163,12 @@ struct S3
inline namespace I2
{
-// expected-note@+1 {{a function associating 'N::I1::E' is declared here [loplugin:external]}}
+// expected-note-re@+1 {{a function associating 'N{{(::I1)?}}::E' is declared here [loplugin:external]}}
void f3(E);
inline namespace I3
{
-// expected-note@+1 {{a function associating 'N::I1::E' is declared here [loplugin:external]}}
+// expected-note-re@+1 {{a function associating 'N{{(::I1)?}}::E' is declared here [loplugin:external]}}
void f4(E);
}
}
diff --git a/compilerplugins/clang/test/makeshared.cxx b/compilerplugins/clang/test/makeshared.cxx
index d3ac22389c8f..d6c3cbdac736 100644
--- a/compilerplugins/clang/test/makeshared.cxx
+++ b/compilerplugins/clang/test/makeshared.cxx
@@ -54,9 +54,9 @@ void test2()
(void)y;
std::unique_ptr<int> u1;
- // expected-error-re@+1 {{rather use make_shared than constructing from {{.+}} (aka 'std{{.*}}::unique_ptr<int, std{{.*}}::default_delete<int>{{ ?}}>') [loplugin:makeshared]}}
+ // expected-error-re@+1 {{rather use make_shared than constructing from {{.+}} (aka 'std{{.*}}::unique_ptr<int{{.*}}>') [loplugin:makeshared]}}
std::shared_ptr<int> z = std::move(u1);
- // expected-error-re@+1 {{rather use make_shared than constructing from {{.+}} (aka 'std{{.*}}::unique_ptr<int, std{{.*}}::default_delete<int>{{ ?}}>') [loplugin:makeshared]}}
+ // expected-error-re@+1 {{rather use make_shared than constructing from {{.+}} (aka 'std{{.*}}::unique_ptr<int{{.*}}>') [loplugin:makeshared]}}
z = std::move(u1);
}