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 7817E385700B for ; Tue, 16 May 2023 09:07:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 7817E385700B 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=1684228032; 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; bh=Lys469ZRgDGbvzUhD4huYoqXSDH91hvsz8M6yq6sR6Q=; b=QaaVy4dvL35X41bBK+kOaHhNr23oYfhkHvGorsKl0kyi2Sf8SzR5cRNWTLcruQAA59ItfA 96uYAGZ7LJ8a+Zraka+rkvJzgF7AUX0jCtIEDgK+4x6/oWKtAOdFjJBQsFei/afkmKv9MR 2de9lPUw07Nl1Alxv21nQP1hEfLXkyk= 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-587-wW1OW2HROVC5z9_JwvJpxQ-1; Tue, 16 May 2023 05:07:10 -0400 X-MC-Unique: wW1OW2HROVC5z9_JwvJpxQ-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 74C1A185A7A2; Tue, 16 May 2023 09:07:10 +0000 (UTC) Received: from localhost (unknown [10.42.28.178]) by smtp.corp.redhat.com (Postfix) with ESMTP id 005571121314; Tue, 16 May 2023 09:07:09 +0000 (UTC) From: Jonathan Wakely To: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org Subject: [committed] libstdc++: Require tzdb support for chrono::zoned_time printer test Date: Tue, 16 May 2023 10:07:08 +0100 Message-Id: <20230516090708.1698284-1-jwakely@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.3 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,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE 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: Tested powerpc64le-linux. Pushed to trunk. -- >8 -- libstdc++-v3/ChangeLog: * testsuite/libstdc++-prettyprinters/chrono.cc: Only test printer for chrono::zoned_time for cx11 ABI and tzdb effective target. --- libstdc++-v3/testsuite/libstdc++-prettyprinters/chrono.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libstdc++-v3/testsuite/libstdc++-prettyprinters/chrono.cc b/libstdc++-v3/testsuite/libstdc++-prettyprinters/chrono.cc index 01a46169393..b5314e025cc 100644 --- a/libstdc++-v3/testsuite/libstdc++-prettyprinters/chrono.cc +++ b/libstdc++-v3/testsuite/libstdc++-prettyprinters/chrono.cc @@ -1,5 +1,6 @@ // { dg-options "-g -O0 -std=gnu++2a" } // { dg-do run { target c++2a } } +// { dg-additional-options "-DTEST_ZONED_TIME" { target tzdb } } // Copyright The GNU Toolchain Authors. // @@ -38,7 +39,7 @@ main() utc_time utc(467664h); // { dg-final { note-test utc {std::chrono::utc_time = { 467664h }} } } -#if _GLIBCXX_USE_CXX11_ABI +#if _GLIBCXX_USE_CXX11_ABI && defined TEST_ZONED_TIME zoned_time zt("Europe/London", half_past_epoch); // { dg-final { note-test zt {std::chrono::zoned_time = { "Europe/London" 1800000ms [1970-01-01 00:30:00] }} { target cxx11_abi } } } #endif -- 2.40.1