summaryrefslogtreecommitdiff
path: root/lib/timespec.h
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2014-12-11 23:16:37 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2014-12-12 16:04:10 -0800
commitb81a1837916a7f3f7abd953338302fa237a532f2 (patch)
treeeab3a9abb613126d80773cc6dd04d3a7b9f22ad3 /lib/timespec.h
parent074965f9355b7cc7f7a5f4385a19433e51c8afd2 (diff)
downloademacs-b81a1837916a7f3f7abd953338302fa237a532f2.tar.gz
Merge from gnulib
2014-12-12 stddef: support C11's max_align_t 2014-12-08 apply _GL_ATTRIBUTE_PURE to some inline functions 2014-12-02 support GNU format printf and scanf on mingw * doc/misc/texinfo.tex, lib/stat-time.h, lib/stddef.in.h: * lib/timespec.h, m4/extensions.m4, m4/stddef_h.m4, m4/stdio_h.m4: Update from gnulib. * lib/gnulib.mk: Regenerate.
Diffstat (limited to 'lib/timespec.h')
-rw-r--r--lib/timespec.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/timespec.h b/lib/timespec.h
index 872cbb76e37..dfc1277a71f 100644
--- a/lib/timespec.h
+++ b/lib/timespec.h
@@ -74,7 +74,7 @@ make_timespec (time_t s, long int ns)
The (int) cast avoids a gcc -Wconversion warning. */
-_GL_TIMESPEC_INLINE int
+_GL_TIMESPEC_INLINE int _GL_ATTRIBUTE_PURE
timespec_cmp (struct timespec a, struct timespec b)
{
return (a.tv_sec < b.tv_sec ? -1
@@ -84,7 +84,7 @@ timespec_cmp (struct timespec a, struct timespec b)
/* Return -1, 0, 1, depending on the sign of A. A.tv_nsec must be
nonnegative. */
-_GL_TIMESPEC_INLINE int
+_GL_TIMESPEC_INLINE int _GL_ATTRIBUTE_PURE
timespec_sign (struct timespec a)
{
return a.tv_sec < 0 ? -1 : a.tv_sec || a.tv_nsec;