From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from omta002.cacentral1.a.cloudfilter.net (omta002.cacentral1.a.cloudfilter.net [3.97.99.33]) by sourceware.org (Postfix) with ESMTPS id 6CB98386184C for ; Wed, 26 Oct 2022 03:05:50 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 6CB98386184C Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=SystematicSw.ab.ca Authentication-Results: sourceware.org; spf=none smtp.mailfrom=systematicsw.ab.ca Received: from shw-obgw-4004a.ext.cloudfilter.net ([10.228.9.227]) by cmsmtp with ESMTP id nJmfoqGCxSp39nWjloZGDm; Wed, 26 Oct 2022 03:05:49 +0000 Received: from [10.0.0.5] ([184.64.124.72]) by cmsmtp with ESMTP id nWjkozmgQlz8pnWjloXzpE; Wed, 26 Oct 2022 03:05:49 +0000 X-Authority-Analysis: v=2.4 cv=VvEwvs6n c=1 sm=1 tr=0 ts=6358a40d a=oHm12aVswOWz6TMtn9zYKg==:117 a=oHm12aVswOWz6TMtn9zYKg==:17 a=IkcTkHD0fZMA:10 a=wGc9a98Y0es38I_Qc1YA:9 a=QEXdDO2ut3YA:10 Message-ID: Date: Tue, 25 Oct 2022 21:05:48 -0600 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.4.0 Reply-To: newlib@sourceware.org Subject: Re: [PATCH] strftime.c(__strftime): add %q, %v, tests; tweak %Z doc Content-Language: en-CA To: newlib@sourceware.org References: <20221022051352.2723-1-Brian.Inglis@SystematicSW.ab.ca> <40664e92-d899-fc28-9321-0fb3b97931e8@SystematicSw.ab.ca> From: Brian Inglis Organization: Systematic Software In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-CMAE-Envelope: MS4xfEHyiYDGMgr1nskOLIM3UaHKZYh8uOmZcYRq3ixlxCSR65DovkHEEQl8GJWoAVEfy66KJpSgBV7ZMsGY+J2/Kf48/HS5dJvI9ds0XDLZSXksTdXQnVVy w5M/pPQMX2T5Y3GJ3tEvzrO1POWyOrvo4cGUNpDS+4nshcE0TzUSNrwPokXyV+vfJd2NH7Fj/mi/QfodlSLoHNKd4lkZKgAULpE= X-Spam-Status: No, score=-1163.7 required=5.0 tests=BAYES_00,KAM_DMARC_STATUS,KAM_LAZY_DOMAIN_SECURITY,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2022-10-25 04:38, Corinna Vinschen wrote: > On Oct 24 17:50, Brian Inglis wrote: >> On 2022-10-24 06:07, Corinna Vinschen wrote: >>> On Oct 21 23:13, Brian Inglis wrote: >>>> + case CQ('v'): /* BSD/OSX/Ruby extension VMS/Oracle date format >>>> + from Arnold Robbins strftime version 3.0 */ >>>> + { /* %v is equivalent to "%e-%b-%Y", flags and width can change year >>> ^^^^^ >>> pad? >>>> + format. Recurse to avoid need to replicate %b and %Y formation. */ >>> >>> Sorry for being a nag, but doesn't that introduce an incompatible >>> change? The BSDs don't handle pad and width, they just call >>> _fmt("%e-%b-%Y", ...). Or am I missing how the BSD function works? >> >> Yes if this function was actually BSD-like, but newlib strftime supports all >> the POSIX and GNU flags (including +, which was why why I couldn't add BSD >> %+ for default locale formatting), so I thought I should add POSIX extended >> year handling to support the extended year range and formats required, for >> compatibility with other %Y formatting in that function, and tests of that >> functionality. > > Sounds ok to me on second thought. Pushed. Cheers! -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retirer but when there is no more to cut -- Antoine de Saint-Exupéry