From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-3.5 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.1 Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 926771F915 for ; Sat, 14 Jul 2018 13:50:22 +0000 (UTC) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:references:date:in-reply-to :message-id:mime-version:content-type:content-transfer-encoding; q=dns; s=default; b=sNWG6NWmXHoDEeGeBguGFDfGwMNwvr0NhgayhM5ihdV 2C35HKag3J6y6AvH5o4CVzmKbjg22s9QWodvuhikNALooijIctPatAJjoMlGzhf0 +nsJx3tBvNOCnCuduMp4n4sUyQgjuPx4lHqqksdCJI3aVGlkv0URkVzI07HR+daQ = DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:references:date:in-reply-to :message-id:mime-version:content-type:content-transfer-encoding; s=default; bh=yv5Wn/tQxxxalKRWHaOu/P2BMHg=; b=ZC5uQ1X+rRpw717/y +WxbFFIx04fB1jWLZEaqdWcX35eWc784u5im9MHUgyowmgY4rqHVOa/tY/9jvzRo 5es/82t4IYf0BI6gTiGIJFSQ/lqt5Uqf0cozIHsOnTJ86oQUHclhzLcfF7gF9QAu upmsM2C1iJPqpcYsgCtzdwkiZs= Received: (qmail 98425 invoked by alias); 14 Jul 2018 13:50:19 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 98415 invoked by uid 89); 14 Jul 2018 13:50:19 -0000 Authentication-Results: sourceware.org; auth=none X-HELO: albireo.enyo.de From: Florian Weimer To: Adhemerval Zanella Cc: libc-alpha@sourceware.org Subject: Re: [PATCH v8 6/8] nptl: Add abilist symbols for C11 threads References: <1517591084-11347-1-git-send-email-adhemerval.zanella@linaro.org> <1517591084-11347-7-git-send-email-adhemerval.zanella@linaro.org> <97b42cb3-e76a-ac71-65cd-c1f6d8c404aa@redhat.com> <90dc04ab-81df-b0d7-a086-d00ea5cc979d@linaro.org> <5ec19a17-30a3-e9b7-9475-c28b247c8daa@redhat.com> <98a36756-5dc8-680b-c065-3501ca4ec7d4@linaro.org> <87muuuc3jw.fsf@mid.deneb.enyo.de> <7f8e17f2-198f-a2cc-8fc1-be1979605229@linaro.org> Date: Sat, 14 Jul 2018 15:50:14 +0200 In-Reply-To: <7f8e17f2-198f-a2cc-8fc1-be1979605229@linaro.org> (Adhemerval Zanella's message of "Fri, 13 Jul 2018 18:09:21 -0300") Message-ID: <87efg6kju1.fsf@mid.deneb.enyo.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable * Adhemerval Zanella: > On 13/07/2018 16:56, Florian Weimer wrote: >> * Adhemerval Zanella: >>=20 >>>> I think ONCE_FLAG_INIT needs to be a compound literal, not an >>>> initializer, at least that's how I read the standard (=E2=80=9Cwhich e= xpands >>>> to a value that can be used to initialize an object=E2=80=9D). >>> >>> Right, you are correct, this will prevent ONCE_FLAG_INIT to be wrongly= =20 >>> used to initialize other objects than once_flag. I adjust to be a=20 >>> struct as well. >>=20 >> Sorry, I forgot that this needs another __cplusplus conditional. >>=20 >> Something like this: >>=20 >> #ifdef __cplusplus >> # define ONCE_FLAG_INIT (once_flag {}) >> #else >> # define ONCE_FLAG_INIT (once_flag) { 0 } >> #endif >>=20 >> Compound literals in C++ are a GCC extension. > > Fixed. This looks fine to me now.