Hello, This patch is a proposal to update the dg-prune-output regex in 20_util/bind/ref_neg.cc to account for possible extra subdirs of include/ before reaching "functional" in out-of-build-tree test runs (c++/10.2.1 in our case).
I noticed only afterwards that many other tests seem to have adopted a simpler // { dg-prune-output "include" } Not entirely sure this would be appropriate here as well. This variant cures the failures we saw when running tests from our gcc-10 installed toolchain and I verified that the test still passes from a build tree on mainline, x86_64-linux host in both cases. Is this ok to commit ? Thanks in advance, Olivier 2020-12-18 Olivier Hainque <hain...@adacore.com> libstdc++-v3/ * testsuite/20_util/bind/ref_neg.cc: Account for out-of-build-tree contexts in the dg-prune-output regexp.
From 8ca4da2b492417752ab1fa7b86b75208ea17adc1 Mon Sep 17 00:00:00 2001 From: Olivier Hainque <hain...@adacore.com> Date: Fri, 18 Dec 2020 18:09:21 +0000 Subject: [PATCH] Tweak dg-prune-output regex for out-of-tree contexts libstdc++-v3/ * testsuite/20_util/bind/ref_neg.cc: Tweak dg-prune-output regex for out-of-tree contexts. --- libstdc++-v3/testsuite/20_util/bind/ref_neg.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libstdc++-v3/testsuite/20_util/bind/ref_neg.cc b/libstdc++-v3/testsuite/20_util/bind/ref_neg.cc index d77ad90cc253..bf9d3c0b3145 100644 --- a/libstdc++-v3/testsuite/20_util/bind/ref_neg.cc +++ b/libstdc++-v3/testsuite/20_util/bind/ref_neg.cc @@ -49,7 +49,8 @@ void test02() } // Ignore the reasons for deduction/substitution failure in the headers. -// { dg-prune-output "/include/(functional|bits/invoke.h):" } +// Account for possible extra subdirs in out-of-tree test runs. +// { dg-prune-output "/include/(c../\[0-9.\]*/)?(functional|bits/invoke.h):" } int main() { -- 2.17.1