From: Josh Triplett <josh@freedesktop.org>
To: Neil Booth <neil@daikokuya.co.uk>
Cc: Damien Lespiau <damien.lespiau@gmail.com>, linux-sparse@vger.kernel.org
Subject: Re: [PATCH] __DATE__ & __TIME expansion
Date: Sun, 20 May 2007 16:02:00 -0700 [thread overview]
Message-ID: <4650D368.1060806@freedesktop.org> (raw)
In-Reply-To: <20070520225019.GA2547@daikokuya.co.uk>
[-- Attachment #1: Type: text/plain, Size: 898 bytes --]
Neil Booth wrote:
> Damien Lespiau wrote:-
>
>> Makes __DATE__expand to a character string literal of
>> the form "Mmm dd yyyy" where the names of the months
>> are the same as those generated by the asctime function,
>> and the first character of dd is a space character if the
>> value is less than 10.
>> Makes __TIME__ expand to a a character string literal of
>> the form "hh:mm:ss" as in the time generated by the
>> asctime function.
>>
>> So says C99.
>>
>> Signed-off-by: Damien Lespiau <damien.lespiau@gmail.com>
>
> It seems your code could lead to these macros having different
> values in a long compilation, which the standard doesn't permit.
Ah, I didn't know that. So calling time more than once doesn't just slow down
compilation; it also violates the standard. I feel better about asking for a
fix to only call time once, now. :)
- Josh Triplett
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 252 bytes --]
next prev parent reply other threads:[~2007-05-20 23:02 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-20 21:59 [PATCH] Beautify all & install Makefile targets Damien Lespiau
2007-05-20 21:59 ` [PATCH] __DATE__ & __TIME expansion Damien Lespiau
2007-05-20 22:50 ` Neil Booth
2007-05-20 23:02 ` Josh Triplett [this message]
2007-05-20 23:49 ` Damien Lespiau
2007-05-21 0:06 ` Derek M Jones
2007-05-20 22:52 ` Josh Triplett
2007-05-21 0:35 ` [PATCH] Beautify all & install Makefile targets Josh Triplett
2007-05-22 18:28 ` Damien Lespiau
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=4650D368.1060806@freedesktop.org \
--to=josh@freedesktop.org \
--cc=damien.lespiau@gmail.com \
--cc=linux-sparse@vger.kernel.org \
--cc=neil@daikokuya.co.uk \
/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 NNTP newsgroup(s).