bug-gnulib
[Top][All Lists]
Advanced

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

Re: declaring only the functions that are defined


From: Paul Eggert
Subject: Re: declaring only the functions that are defined
Date: Tue, 02 Jan 2007 21:16:06 -0800
User-agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.4 (gnu/linux)

Bruno Haible <address@hidden> writes:

> 2007-01-01  Bruno Haible  <address@hidden>
>
>       * lib/timespec.h (nanosleep): Declare only if GNULIB_NANOSLEEP.

I'm a bit dubious about this one, as it adds to the .h maintenance
burden and I'm not sure the benefit is worth the cost.

For the special case of nanosleep, one might want nanosleep declared
even if the nanosleep module isn't being used, for the benefit of
hosts that define nanosleep but don't declare it.  The other changes
don't have this problem, as they're for gnulib-only functions.

Also, in the future, I'm leaning towards modifying gnulib so that
nanosleep and struct timespec are declared by <time.h> instead of
having a special timespec.h include file.  This is more compatible
with POSIX and would be simpler for programs to use.

So perhaps we should leave the nanosleep part alone for now, anyway.

The other parts I'm ambivalent about.




reply via email to

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