unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Rafal Luzynski <digitalfreak@lingonborough.com>
To: Paul Eggert <eggert@cs.ucla.edu>
Cc: Zack Weinberg <zackw@panix.com>,
	GLIBC Devel <libc-alpha@sourceware.org>,
	TAMUKI Shoichi <tamuki@linet.gr.jp>
Subject: Re: 2.29 freeze update: Last fortnight
Date: Tue, 15 Jan 2019 19:16:47 +0100 (CET)	[thread overview]
Message-ID: <86640901.11309.1547576207748@poczta.nazwa.pl> (raw)
In-Reply-To: <390ea752-0dcd-aa51-9a3e-976d702e952f@cs.ucla.edu>

15.01.2019 18:49 Paul Eggert <eggert@cs.ucla.edu> wrote:
> 
> On 1/15/19 9:16 AM, Rafal Luzynski wrote:
>  > https://sourceware.org/ml/libc-alpha/2019-01/msg00239.html
> 
> I took a look at those. Some comments:

Thank you, Paul.

Tamuki Shoichi, please prepare a new version with these remarks
applied.

> [...]
>  >  For %Ey conversion specifier, the default action is now
>  >  to pad the number with zero to keep minimum 2 digits, similar to %y.
>  >+ Also, the optional flag (either _ or -) can be used for %EY, so that
>  >+ the internal %Ey is interpreted as if decorated with the appropriate
>  >+ flag.
> 
> Change to:
> 
> For the %Ey conversion specifier, the default action is now to zero-pad 
> the number to two digits, like %y.  Also, the optional flag (either _ or 
> -) now affects the formatted year, like %EY.

Shouldn't the flags be quoted, like "_" and "-"?  Also, it seems to me that
a line starting with a plain minus sign does not look good.

>  > static size_t __strftime_internal (CHAR_T *, size_t, const CHAR_T *,
>  >-                   const struct tm *, bool *
>  >+                   const struct tm *, int *, bool *
>  >                    ut_argument_spec
>  >                    LOCALE_PARAM) __THROW;
> 
> I also am puzzled as to why the new argument is int * rather than plain 
> int. Why not make it plain int and simplify the rest of the code 
> accordingly?

I guess this is a kind of optimization: if yr_spec is calculated in the
first pass (calculating the width of the output) then there is no need
to calculate it on the second pass.  But I am not sure we want to
sacrifice the simplicity and nice design of the code.

Regards,

Rafal

  reply	other threads:[~2019-01-15 18:16 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-15 14:37 2.29 freeze update: Last fortnight Siddhesh Poyarekar
2019-01-15 16:52 ` Rafal Luzynski
2019-01-15 17:02   ` Zack Weinberg
2019-01-15 17:16     ` Rafal Luzynski
2019-01-15 17:49       ` Paul Eggert
2019-01-15 18:16         ` Rafal Luzynski [this message]
2019-01-15 18:22           ` Paul Eggert
2019-01-15 22:03             ` Rafal Luzynski
2019-01-15 17:09   ` Carlos O'Donell
2019-01-17  6:30     ` TAMUKI Shoichi
2019-01-17  6:29   ` TAMUKI Shoichi
2019-01-17 20:32     ` Rafal Luzynski
2019-01-18 13:58       ` TAMUKI Shoichi
2019-01-18 15:35         ` Rafal Luzynski
2019-01-15 20:09 ` Jochen Hein
2019-01-16  3:44   ` Siddhesh Poyarekar
2019-01-15 20:17 ` Carlos O'Donell
2019-01-16  3:47   ` Siddhesh Poyarekar
2019-01-22  3:28     ` Siddhesh Poyarekar
2019-01-22  3:52       ` H.J. Lu
2019-01-22 22:14         ` Joseph Myers
2019-01-22  4:21       ` Carlos O'Donell
2019-01-22 12:00         ` Florian Weimer
2019-01-22 13:06           ` Carlos O'Donell
2019-01-22 13:11             ` Szabolcs Nagy
2019-01-22 13:23               ` Carlos O'Donell
2019-01-22 15:17                 ` Siddhesh Poyarekar
2019-01-22 15:48                   ` Carlos O'Donell
2019-01-22 16:06                     ` DCO or Copyright Assignment? Why not both Siddhesh Poyarekar
2019-01-28 13:00                       ` Florian Weimer
2019-01-22 10:18       ` 2.29 freeze update: Last fortnight Rafal Luzynski
2019-01-16  3:13 ` H.J. Lu

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

  List information: https://www.gnu.org/software/libc/involved.html

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

  git send-email \
    --in-reply-to=86640901.11309.1547576207748@poczta.nazwa.pl \
    --to=digitalfreak@lingonborough.com \
    --cc=eggert@cs.ucla.edu \
    --cc=libc-alpha@sourceware.org \
    --cc=tamuki@linet.gr.jp \
    --cc=zackw@panix.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).