From 4c9e5b02f08b1b02f9b498c5121d06dea3f2c1c4 Mon Sep 17 00:00:00 2001 From: Paolo Carlini Date: Fri, 17 Jan 2020 20:02:21 +0100 Subject: [PATCH] Add testcase of PR c++/92542, already fixed. PR c++/92542 * g++.dg/pr92542.C: New. --- gcc/testsuite/g++.dg/pr92542.C | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 gcc/testsuite/g++.dg/pr92542.C diff --git a/gcc/testsuite/g++.dg/pr92542.C b/gcc/testsuite/g++.dg/pr92542.C new file mode 100644 index 00000000000..d71f515f268 --- /dev/null +++ b/gcc/testsuite/g++.dg/pr92542.C @@ -0,0 +1,15 @@ +template +struct S +{ + S(T, T) { } +}; + +char* begin(); +char* end(); + +void +test01() +{ + S s(begin(). end()); // { dg-error "request for member" "" { target c++17 } } + // { dg-error "missing" "" { target c++14_down } .-1 } +} -- 2.30.2