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 [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id A24B43857705 for ; Mon, 11 Sep 2023 16:35:39 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A24B43857705 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1694450139; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=6gYClcd2HIW6km7oCikZ2bJ1TlsQ5E8GdBzWQdX7d4U=; b=KXQ/GrXoDFMOIBrxaELNmL2HscYc92hTxzuV49XwfHWJmVwkppLg6AAXhspsuQalYuwxCk D83ZcfeV7igJesFOfmK9ySmtxtaGuBEZLV00HBCBHZsgPTyA6DcVGJtdEYfRs6Aa4bRSqp ogoVByakeMCmADcS84CvCjjQ0Bo3Efs= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-53-WGKBi-BtOiKe4a63dbLqKA-1; Mon, 11 Sep 2023 12:35:37 -0400 X-MC-Unique: WGKBi-BtOiKe4a63dbLqKA-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 6791A933723; Mon, 11 Sep 2023 16:35:37 +0000 (UTC) Received: from localhost (unknown [10.42.28.190]) by smtp.corp.redhat.com (Postfix) with ESMTP id 278962156701; Mon, 11 Sep 2023 16:35:37 +0000 (UTC) From: Jonathan Wakely To: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org Subject: [PATCH 02/13] libstdc++: Replace dg-options "-std=c++11" with dg-add-options strict_std Date: Mon, 11 Sep 2023 17:16:33 +0100 Message-ID: <20230911163534.1913512-3-jwakely@redhat.com> In-Reply-To: <20230911163534.1913512-1-jwakely@redhat.com> References: <20230911163534.1913512-1-jwakely@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,KAM_SHORT,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: These tests can (and should) also be run for later standards, so replace the { dg-options "-std=c++11" } with { dg-add-options strict_std } and a target selector for c++11. libstdc++-v3/ChangeLog: * testsuite/23_containers/deque/48101-2_neg.cc: Replace dg-options with target selector. * testsuite/23_containers/forward_list/48101-2_neg.cc: Likewise. * testsuite/23_containers/list/48101-2_neg.cc: Likewise. * testsuite/23_containers/map/48101-2_neg.cc: Likewise. * testsuite/23_containers/map/48101_neg.cc: Likewise. * testsuite/23_containers/multimap/48101-2_neg.cc: Likewise. * testsuite/23_containers/multimap/48101_neg.cc: Likewise. * testsuite/23_containers/multiset/48101-2_neg.cc: Likewise. * testsuite/23_containers/set/48101-2_neg.cc: Likewise. * testsuite/23_containers/unordered_map/48101-2_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/48101-2_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/48101-2_neg.cc: Likewise. * testsuite/23_containers/unordered_set/48101-2_neg.cc: Likewise. * testsuite/23_containers/vector/48101-2_neg.cc: Likewise. --- libstdc++-v3/testsuite/23_containers/deque/48101-2_neg.cc | 4 ++-- .../testsuite/23_containers/forward_list/48101-2_neg.cc | 4 ++-- libstdc++-v3/testsuite/23_containers/list/48101-2_neg.cc | 4 ++-- libstdc++-v3/testsuite/23_containers/map/48101-2_neg.cc | 4 ++-- libstdc++-v3/testsuite/23_containers/map/48101_neg.cc | 3 +-- libstdc++-v3/testsuite/23_containers/multimap/48101-2_neg.cc | 4 ++-- libstdc++-v3/testsuite/23_containers/multimap/48101_neg.cc | 3 +-- libstdc++-v3/testsuite/23_containers/multiset/48101-2_neg.cc | 4 ++-- libstdc++-v3/testsuite/23_containers/set/48101-2_neg.cc | 4 ++-- .../testsuite/23_containers/unordered_map/48101-2_neg.cc | 4 ++-- .../testsuite/23_containers/unordered_multimap/48101-2_neg.cc | 4 ++-- .../testsuite/23_containers/unordered_multiset/48101-2_neg.cc | 4 ++-- .../testsuite/23_containers/unordered_set/48101-2_neg.cc | 4 ++-- libstdc++-v3/testsuite/23_containers/vector/48101-2_neg.cc | 4 ++-- 14 files changed, 26 insertions(+), 28 deletions(-) diff --git a/libstdc++-v3/testsuite/23_containers/deque/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/deque/48101-2_neg.cc index 041f0cb88b3..d5cb13ec4db 100644 --- a/libstdc++-v3/testsuite/23_containers/deque/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/deque/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/forward_list/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/forward_list/48101-2_neg.cc index 2a21876c1cf..d5cc81c6b48 100644 --- a/libstdc++-v3/testsuite/23_containers/forward_list/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/forward_list/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/list/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/list/48101-2_neg.cc index 0e96022cdfe..5cea21992d9 100644 --- a/libstdc++-v3/testsuite/23_containers/list/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/list/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/map/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/map/48101-2_neg.cc index 06c4dc9e9ef..8cda993e2cb 100644 --- a/libstdc++-v3/testsuite/23_containers/map/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/map/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/map/48101_neg.cc b/libstdc++-v3/testsuite/23_containers/map/48101_neg.cc index e9029caad21..81837954125 100644 --- a/libstdc++-v3/testsuite/23_containers/map/48101_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/map/48101_neg.cc @@ -15,8 +15,7 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } #include diff --git a/libstdc++-v3/testsuite/23_containers/multimap/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/multimap/48101-2_neg.cc index fd77071a2a5..6022039e004 100644 --- a/libstdc++-v3/testsuite/23_containers/multimap/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/multimap/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/multimap/48101_neg.cc b/libstdc++-v3/testsuite/23_containers/multimap/48101_neg.cc index 942a5aaf2ff..55626edfc2d 100644 --- a/libstdc++-v3/testsuite/23_containers/multimap/48101_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/multimap/48101_neg.cc @@ -15,8 +15,7 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } #include diff --git a/libstdc++-v3/testsuite/23_containers/multiset/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/multiset/48101-2_neg.cc index c1c1f64d6c5..619b97ee4a5 100644 --- a/libstdc++-v3/testsuite/23_containers/multiset/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/multiset/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/set/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/set/48101-2_neg.cc index 6466b38901d..d83a08c9856 100644 --- a/libstdc++-v3/testsuite/23_containers/set/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/set/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/unordered_map/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/unordered_map/48101-2_neg.cc index 8ea74e6c04b..c45ef0daa50 100644 --- a/libstdc++-v3/testsuite/23_containers/unordered_map/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/unordered_map/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/unordered_multimap/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/unordered_multimap/48101-2_neg.cc index 38afec91b34..39eeb0f76d8 100644 --- a/libstdc++-v3/testsuite/23_containers/unordered_multimap/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/unordered_multimap/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/unordered_multiset/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/unordered_multiset/48101-2_neg.cc index 389cb947cbe..006716e0d69 100644 --- a/libstdc++-v3/testsuite/23_containers/unordered_multiset/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/unordered_multiset/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/unordered_set/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/unordered_set/48101-2_neg.cc index 08ef3b587a4..ed5a7787525 100644 --- a/libstdc++-v3/testsuite/23_containers/unordered_set/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/unordered_set/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include diff --git a/libstdc++-v3/testsuite/23_containers/vector/48101-2_neg.cc b/libstdc++-v3/testsuite/23_containers/vector/48101-2_neg.cc index ed5111224e9..0dd75956ce6 100644 --- a/libstdc++-v3/testsuite/23_containers/vector/48101-2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/vector/48101-2_neg.cc @@ -15,8 +15,8 @@ // with this library; see the file COPYING3. If not see // . -// { dg-do compile } -// { dg-options "-std=c++11" } +// { dg-do compile { target c++11 } } +// { dg-add-options strict_std } #include -- 2.41.0