From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oa1-x2c.google.com (mail-oa1-x2c.google.com [IPv6:2001:4860:4864:20::2c]) by sourceware.org (Postfix) with ESMTPS id 871C8385703A for ; Wed, 22 Mar 2023 13:11:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 871C8385703A Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-oa1-x2c.google.com with SMTP id 586e51a60fabf-17aaa51a911so19364424fac.5 for ; Wed, 22 Mar 2023 06:11:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679490684; h=content-transfer-encoding:in-reply-to:organization:references:to :from:content-language:subject:user-agent:mime-version:date :message-id:from:to:cc:subject:date:message-id:reply-to; bh=TDMEnxSl4vlm1Ar9DZc6g7YV08G3gh5zmIAvSX5mLFg=; b=eqMaE/dSM+hjC8jAt6f4Fiy0A3HbkmblI6T7XS4KfJLdGpnjd8EfLyBOpfuZIhMbP5 JyRcCr2SN0RmkIwb73vqRsBI1KwRCkjWfGLpI8+GEi8wlSosr1Ussc1ieZKcfCy020/O 8fzXqnTe94gQQ9c8heOCFkw+9nHm7JWFbr6nmbzNnw+W9ebat1KMhz4Pse9cMgD7Euks 1p7wLJIPYuM3KtzuB94Wt2DXwSi7gFXrPpMduhyniL6JXE/MjzRTp2LOt0dIOhrntkKl HUHeszqdylvgdvQOCPaRMIPzRViZk2XZhC6DQQK0v1iGEhfTlf3RlWQAnerjxcuZTuIk WkeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679490684; h=content-transfer-encoding:in-reply-to:organization:references:to :from:content-language:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=TDMEnxSl4vlm1Ar9DZc6g7YV08G3gh5zmIAvSX5mLFg=; b=Cu5AJz7pqBtDf7/kp/RpIb3h+fIMQAjSWNRAQKZR7iy1BBgjDkSQOsHOaqIc3yPcW0 eukgQsI3dxsjJDUTicoIAo26ZbP9ZDjyCPjGAsqC01QqwNpPnWVpiF4wj/AEH4sQ/hW+ D9lOwS1knxTZkJ/Yn8H+RNfJ4i77pOxKv/DmwuV+q89ra/WuT54A9EfSck2ZTohFFtiz vWccq8Y4kplnjWbJY8wGSnj/FaQWDLHwsCI0DEocETZ0Y0JfC3WqFdcw2sSGoDh9dyVC UF7n3IjvRqAfIrTZ0f57zEW4muIaOlVMFDMjhGu7Jp4wYSvO3QTNLxAkjH6VorAClQIv 3V3Q== X-Gm-Message-State: AO0yUKWvRgZFq/fPqPw2sBU4w1PKDeI8Zg4YCty+cuxe+t0h/SVvXTYZ YD38sQpMHUEKR1vBfuuPc37iBJj3iupvG/v3DJl4ng== X-Google-Smtp-Source: AK7set/08o1h3n9usi+qH3IBAPOSe8UpeneiANSmBzjNqEmV75x2f8UhP4z6YXluDApazRLjjHdrfw== X-Received: by 2002:a05:6870:b019:b0:177:a743:8198 with SMTP id y25-20020a056870b01900b00177a7438198mr1329294oae.6.1679490684250; Wed, 22 Mar 2023 06:11:24 -0700 (PDT) Received: from ?IPV6:2804:1b3:a7c0:c260:d4b6:6c90:6159:ac3d? ([2804:1b3:a7c0:c260:d4b6:6c90:6159:ac3d]) by smtp.gmail.com with ESMTPSA id zj22-20020a0568716c9600b0017ae6741157sm5184622oab.4.2023.03.22.06.11.22 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 22 Mar 2023 06:11:23 -0700 (PDT) Message-ID: <18ef4af7-d89d-01a7-628b-7287679eec06@linaro.org> Date: Wed, 22 Mar 2023 10:11:21 -0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 Subject: Re: [PATCH v2] wchar: Define va_list for POSIX (BZ #30035) Content-Language: en-US From: Adhemerval Zanella Netto To: libc-alpha@sourceware.org, Andreas Schwab References: <20230124174959.1718640-1-adhemerval.zanella@linaro.org> <61890062-04b1-d709-abf3-ede0ba32bd0e@linaro.org> Organization: Linaro In-Reply-To: <61890062-04b1-d709-abf3-ede0ba32bd0e@linaro.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-12.0 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,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: Ping (x2). On 09/02/23 16:43, Adhemerval Zanella Netto wrote: > Ping. > > On 24/01/23 14:49, Adhemerval Zanella wrote: >> This was uncovered by a recent clang change [1]. Different than ISO C, >> POSIX states that va_list should be exported by wchar.h [2]. >> >> Checked on x86_64-linux-gnu and aarch64-linux-gnu. >> >> [1] https://reviews.llvm.org/D137268 >> [2] https://pubs.opengroup.org/onlinepubs/9699919799.2018edition/basedefs/wchar.h.html >> --- >> conform/data/wchar.h-data | 3 +++ >> wcsmbs/wchar.h | 11 +++++++++++ >> 2 files changed, 14 insertions(+) >> >> diff --git a/conform/data/wchar.h-data b/conform/data/wchar.h-data >> index e414651a33..0af74e14bc 100644 >> --- a/conform/data/wchar.h-data >> +++ b/conform/data/wchar.h-data >> @@ -15,6 +15,9 @@ type size_t >> type locale_t >> # endif >> tag {struct tm} >> +# if !defined ISO99 && !defined ISO11 && !defined UNIX98 >> +type va_list >> +# endif >> >> function wint_t btowc (int) >> function int fwprintf (FILE*, const wchar_t*, ...) >> diff --git a/wcsmbs/wchar.h b/wcsmbs/wchar.h >> index 69e920b8c2..ca145bb8d2 100644 >> --- a/wcsmbs/wchar.h >> +++ b/wcsmbs/wchar.h >> @@ -37,6 +37,17 @@ >> #define __need___va_list >> #include >> >> +#if defined __USE_XOPEN2K || defined __USE_XOPEN2K8 >> +# ifdef __GNUC__ >> +# ifndef _VA_LIST_DEFINED >> +typedef __gnuc_va_list va_list; >> +# define _VA_LIST_DEFINED >> +# endif >> +# else >> +# include >> +# endif >> +#endif >> + >> #include >> #include >> #include