From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 106430 invoked by alias); 3 Jul 2019 22:35:25 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 106382 invoked by uid 89); 3 Jul 2019 22:35:25 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy=2069, HContent-Transfer-Encoding:8bit X-HELO: mail-wm1-f47.google.com Received: from mail-wm1-f47.google.com (HELO mail-wm1-f47.google.com) (209.85.128.47) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 03 Jul 2019 22:35:23 +0000 Received: by mail-wm1-f47.google.com with SMTP id h19so3914188wme.0 for ; Wed, 03 Jul 2019 15:35:23 -0700 (PDT) Return-Path: Received: from Jamess-MacBook.local (global-184-8.nat-1.net.cam.ac.uk. [131.111.184.8]) by smtp.gmail.com with ESMTPSA id i18sm797003wrp.91.2019.07.03.15.35.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 03 Jul 2019 15:35:20 -0700 (PDT) Received: by Jamess-MacBook.local (Postfix, from userid 501) id A9ED9205066C66; Wed, 3 Jul 2019 23:35:19 +0100 (BST) From: James Clarke To: gcc-patches@gcc.gnu.org Cc: James Clarke Subject: [PATCH] [Ada] Make clockid_t type public on GNU/kFreeBSD Date: Wed, 03 Jul 2019 22:38:00 -0000 Message-Id: <20190703223514.65803-1-jrtc27@debian.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SW-Source: 2019-07/txt/msg00310.txt.bz2 From: James Clarke Monotonic_Clock and RT_Resolution in the recently-added s-tpopmo.adb call clock_gettime/clock_getres with the integral constants from OSC and thus rely on clockid_t being an integral type, so we cannot hide it on GNU/kFreeBSD. Instead, make the definition public to match all the other implementations. gcc/ada * libgnarl/s-osinte__kfreebsd-gnu.ads (clockid_t): Make type definition public. (CLOCK_REALTIME): Make value public. --- gcc/ada/libgnarl/s-osinte__kfreebsd-gnu.ads | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/gcc/ada/libgnarl/s-osinte__kfreebsd-gnu.ads b/gcc/ada/libgnarl/s-osinte__kfreebsd-gnu.ads index 408187314..b60ffd2c0 100644 --- a/gcc/ada/libgnarl/s-osinte__kfreebsd-gnu.ads +++ b/gcc/ada/libgnarl/s-osinte__kfreebsd-gnu.ads @@ -206,9 +206,8 @@ package System.OS_Interface is function nanosleep (rqtp, rmtp : access timespec) return int; pragma Import (C, nanosleep, "nanosleep"); - type clockid_t is private; - - CLOCK_REALTIME : constant clockid_t; + type clockid_t is new int; + CLOCK_REALTIME : constant clockid_t := 0; function clock_gettime (clock_id : clockid_t; @@ -607,9 +606,6 @@ private end record; pragma Convention (C, timespec); - type clockid_t is new int; - CLOCK_REALTIME : constant clockid_t := 0; - type pthread_attr_t is record detachstate : int; schedpolicy : int; -- 2.17.1