public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Szabolcs Nagy <szabolcs.nagy@arm.com>
To: "Pádraig Brady" <P@draigBrady.com>, libc-alpha@sourceware.org
Cc: <nd@arm.com>
Subject: Re: [PATCH] strftime: support %q to output the quarter of year
Date: Fri, 04 Nov 2016 12:41:00 -0000	[thread overview]
Message-ID: <581C81FA.4070000@arm.com> (raw)
In-Reply-To: <9877d75d-37b2-15e9-9be8-b4d178813eec@draigBrady.com>

On 04/11/16 12:23, Pádraig Brady wrote:
> On 04/11/16 12:07, Szabolcs Nagy wrote:
>> On 04/11/16 12:00, Pádraig Brady wrote:
>>> On 04/11/16 11:41, Szabolcs Nagy wrote:
>>>> On 03/11/16 19:46, Pádraig Brady wrote:
>>>>> This is already supported by gnulib.
>>>
>>>> why?
>>>
>>> It's a marginal benefit, but as
>>> noted in the cover of my updated patch:
>>>
>>> "Note even though the code is trivial here,
>>> %q is useful from the shell as there you need to:
>>> $(( ($(date +%-m)-1)/3+1 ))".
>>>
>>> I'll add that to the actual commit.
>>
>> this can conflict with future standard, so
>> there need to be a strong reason for adding
>> such extensions to portability libraries
>> such as gnulib or to c runtimes.
>>
>> how does gnulib plan to deal with the conflict
>> once posix adds %q with different meaning?
> 
> Perl's date lib also uses %q for quarter.

i don't know what "Perl's date lib" is,
the perl DateTime module does not seem to support %q.
https://metacpan.org/pod/DateTime#strftime-Patterns

> So between that and gnulib (and glibc?)
> POSIX would be unlikely to choose %q for something else.
> In any case I intend to propose it to the POSIX folks.
> 
> thanks,
> Pádraig
> 

  reply	other threads:[~2016-11-04 12:41 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-03 19:46 Pádraig Brady
2016-11-03 19:58 ` Florian Weimer
2016-11-03 20:28   ` Adhemerval Zanella
2016-11-03 22:00   ` Joseph Myers
2016-11-04  1:47 ` Pádraig Brady
2016-11-04  4:12   ` Paul Eggert
2016-11-04 11:33 ` Rafal Luzynski
2016-11-04 14:27   ` [PATCH v3] strftime,strptime: have %q represent " Pádraig Brady
2016-11-04 11:41 ` [PATCH] strftime: support %q to output " Szabolcs Nagy
2016-11-04 12:00   ` Pádraig Brady
2016-11-04 12:08     ` Szabolcs Nagy
2016-11-04 12:23       ` Pádraig Brady
2016-11-04 12:41         ` Szabolcs Nagy [this message]
2016-11-04 12:58           ` Pádraig Brady
2016-11-04 13:12         ` keld
2016-11-04 14:12           ` Szabolcs Nagy
2016-11-04 14:57             ` Adhemerval Zanella
2016-11-05  7:19             ` keld

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=581C81FA.4070000@arm.com \
    --to=szabolcs.nagy@arm.com \
    --cc=P@draigBrady.com \
    --cc=libc-alpha@sourceware.org \
    --cc=nd@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).