DMARC-Filter: OpenDMARC Filter v1.4.2 delorie.com 53PLcf8i3544518 Authentication-Results: delorie.com; dmarc=pass (p=none dis=none) header.from=cygwin.com Authentication-Results: delorie.com; spf=pass smtp.mailfrom=cygwin.com DKIM-Filter: OpenDKIM Filter v2.11.0 delorie.com 53PLcf8i3544518 Authentication-Results: delorie.com; dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=Y34FqxX7 X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A6C4A3857350 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1745617119; bh=3klekZl+EoAyvRPnwrXiZ/Kj6gWuqk8DKL3jDGEvYUg=; h=Date:Subject:To:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=Y34FqxX7gSvXP3daz460wXlUCjUPPKmLfB0+n/FGCv2tlUBOp6pFcXMGaxi5yIVET YPXgZBgoB+HxVgEafM6BgaMdxxBpGeAFnEv7ixO3YW5l7yGaXEBIx2VsGR6JC+cwhC QlQ68OMfx5NNDu/upB3RSpt/nLGcr2UpDS6wKWOw= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B2E163858D20 ARC-Filter: OpenARC Filter v1.0.0 sourceware.org B2E163858D20 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1745617057; cv=none; b=MpN2qDlTncS/Cf0XMIo6beH4DqS2wLLhhKIXUJcZXBQc+qLSUEW3PODnPdoquO7Dn5yMYIQ8QqtSS+QsJ+ACfQ3syXBvK14xCwsAlhWQYkjNpXls9dVLbPsyd7XAbn+sUHwFcgDi+XWLCdU84gOWtsS1j85/jGTGMOERFkGa6bk= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1745617057; c=relaxed/simple; bh=rRJ2NVSAPfJrXFqE7wutvhy3SBUqNVH2dTH2UQlySYI=; h=Message-ID:Date:MIME-Version:Subject:To:From; b=uruixnOTrSWGd4kn+ZkwGS5ivO/OvwrGyQ9X0MQteNa7l09EjDZHjeHYGog3pKVOpKNLMdgoXOJE2fdI8p0pEH//yLsOrjfIt5z43s36uWMEAxgtgsPPtmXWPBcYEvDbEPth/Cebe9OrBYXv/0vf/hG9Rv1LGhkesWEEXstZTck= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B2E163858D20 Message-ID: Date: Fri, 25 Apr 2025 14:37:31 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: tfind missing a const qualifier. To: cygwin AT cygwin DOT com References: <87tt6exmpo DOT fsf AT gmail DOT com> Content-Language: en-US In-Reply-To: <87tt6exmpo.fsf@gmail.com> X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.30 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Mark Geisert via Cygwin Reply-To: Mark Geisert Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" Hi Collin, On 4/23/2025 8:28 PM, Collin Funk via Cygwin wrote: > Hi, > > While testing gnulib I noticed that tfind on cygwin is defined like: > > void *tfind (const void *, void **, > int (*) (const void *, const void *)); > > But POSIX requires [1] (*): > > void *tfind (const void *key, void *const *rootp, > int (*compar) (const void *, const void *)); > > For programs written expecting the POSIX prototype, there will be many > warnings that 'rootp' has it's const qualifier discarded. > > Collin > > [1] https://pubs.opengroup.org/onlinepubs/9799919799/functions/tfind.html > > (*) Ignoring the fact that POSIX.1-2024 added the requirement for > 'typedef void posix_tnode;'. Thanks for the report. tfind() and friends are supplied by newlib. I will look into what exactly to report there and/or send a patch there. It appears a bit more from that POSIX version needs implementation. ..mark -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple