[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: stat-time.h vs. -Waggregate-return

From: Eric Blake
Subject: Re: stat-time.h vs. -Waggregate-return
Date: Thu, 02 Aug 2012 17:27:35 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120717 Thunderbird/14.0

On 08/02/2012 04:49 PM, Paul Eggert wrote:
> On 08/02/2012 03:40 PM, Eric Blake wrote:
>> /* Store *ST's access time into *TS.  */
>> static inline void
>> get_stat_atime (struct stat const *st, struct timespec *ts)
> I'd rather not go that route, as the functional style is easier
> to read -- in particular, it tends to avoid aliasing issues.
> In the GNU apps I'm familiar with (Emacs, coreutils, ...)
> we simply disable -Waggregate-return.  It a completely
> anachronistic warning, since its motivation was to
> support backwards compatibility with C compilers that
> did not allow returning structures.  Those compilers
> are long dead and are no longer of practical concern.

Fair enough; that argues that 'manywarnings' should be customized to
easily ditch this and other anachronistic warnings (for example,
-Wtraditional, -Wlong-long) in one line, rather than making every single
client repeat the same list of customizations.

Eric Blake   address@hidden    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]