From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by sourceware.org (Postfix) with ESMTP id 402A73870891 for ; Thu, 14 Jan 2021 13:54:09 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 402A73870891 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-551-aEIGMIE5OliXUIubyxQcZQ-1; Thu, 14 Jan 2021 08:54:07 -0500 X-MC-Unique: aEIGMIE5OliXUIubyxQcZQ-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id DA301107ACF7; Thu, 14 Jan 2021 13:54:05 +0000 (UTC) Received: from localhost (unknown [10.33.37.44]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7089710023B3; Thu, 14 Jan 2021 13:54:05 +0000 (UTC) Date: Thu, 14 Jan 2021 13:54:01 +0000 From: Jonathan Wakely To: =?iso-8859-1?Q?Fran=E7ois?= Dumont Cc: Alexandre Oliva , libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org, Corentin Gay Subject: Re: Split wchars tests from the normal variant Message-ID: <20210114135401.GF7692@redhat.com> References: <9f028d7d-05c9-ff15-1496-cc31ac67886a@gmail.com> MIME-Version: 1.0 In-Reply-To: <9f028d7d-05c9-ff15-1496-cc31ac67886a@gmail.com> X-Clacks-Overhead: GNU Terry Pratchett X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-14.6 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libstdc++@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libstdc++ mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Jan 2021 13:54:10 -0000 On 28/12/20 19:39 +0100, François Dumont via Libstdc++ wrote: >On 22/12/20 10:27 pm, Alexandre Oliva wrote: >>This change extracts apart the wchar specific parts of character >>conversion tests to allow conditonalizating these parts on actual >>wchar support while applying the rest more generally. >> >>This turned out useful during our work on the libstdc++ support >>for VxWorks, to expose the problematic areas more precisely. >> >>Regstrapped on x86_64-linux-gnu, and tested with -x-arm-wrs-vxworks7r2. >>Ok to install? (dg-requires-wchars is added by another patch by >>Corentin, that I posted a few minutes ago) >> >>While updating Corentin's patch for mainline, I brought over to the >>split-out test even the preprocessor conditional that is present in the >>current version of the test, but required/implied by dg-requires-wchars. >>Maybe that's excessive. Maybe the whole patch is excessive, given that >>conditional, but I didn't want to just drop it without asking for >>others' thoughts. >> >> >>from Corentin Gay >>for libstdc++-v3/ChangeLog >> >> * testsuite/20_util/from_chars/1_neg.cc: Split wchar specific >> part into... >> * testsuite/20_util/from_chars/1_neg_wchar.cc: ... new file. >>--- >> libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc | 8 ----- >> .../testsuite/20_util/from_chars/1_neg_wchar.cc | 35 ++++++++++++++++++++ >> 2 files changed, 35 insertions(+), 8 deletions(-) >> create mode 100644 libstdc++-v3/testsuite/20_util/from_chars/1_neg_wchar.cc >> >>diff --git a/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc b/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc >>index 0d2fe2b3e6594..a84b0f5efb075 100644 >>--- a/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc >>+++ b/libstdc++-v3/testsuite/20_util/from_chars/1_neg.cc >>@@ -23,14 +23,6 @@ >> void >> test01(const char* first, const char* last) >> { >>-#if _GLIBCXX_USE_WCHAR_T >>- wchar_t wc; >>-#else >>- enum W { } wc; >>-#endif >>- std::from_chars(first, last, wc); // { dg-error "no matching" } >>- std::from_chars(first, last, wc, 10); // { dg-error "no matching" } >>- >> char16_t c16; >> std::from_chars(first, last, c16); // { dg-error "no matching" } >> std::from_chars(first, last, c16, 10); // { dg-error "no matching" } >>diff --git a/libstdc++-v3/testsuite/20_util/from_chars/1_neg_wchar.cc b/libstdc++-v3/testsuite/20_util/from_chars/1_neg_wchar.cc >>new file mode 100644 >>index 0000000000000..2d736a28a2da7 >>--- /dev/null >>+++ b/libstdc++-v3/testsuite/20_util/from_chars/1_neg_wchar.cc > >AFAIK _neg should be last. Yup. >Using wchar_t_neg.cc should even make the dg-require-wchars useless here. Indeed, but I don't think we want this change anyway.