[PATCH] strftime.c(__strftime): add %q, %v, tests; tweak %Z doc
Brian Inglis
Brian.Inglis@SystematicSw.ab.ca
Wed Oct 26 03:05:48 GMT 2022
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
More information about the Newlib
mailing list