diff lib/savewd.c @ 17181:a80e4b259d9b

chdir-long, cycle-check, savewd: better 'inline' * lib/chdir-long.c (cdb_init, cdb_fchdir, cdb_free) (find_non_slash): * lib/cycle-check.c (is_zero_or_power_of_two): * lib/savewd.c (savewd_delegating): Change 'static inline' to 'inline'. * lib/savewd.c, lib/savewd.h (SAVEWD_INLINE): New macro. Replace all remaining uses of 'static inline' with it. * lib/savewd.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END. * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): * m4/cycle-check.m4 (gl_CYCLE_CHECK): * m4/savewd.m4 (gl_SAVEWD): Do not require AC_C_INLINE. * modules/savewd (Depends-on): Add extern-inline.
author Paul Eggert <eggert@cs.ucla.edu>
date Tue, 20 Nov 2012 22:25:08 -0800 (2012-11-21)
parents 8250f2777afc
children e542fd46ad6f
line wrap: on
line diff
--- a/lib/savewd.c
+++ b/lib/savewd.c
@@ -19,6 +19,8 @@
 
 #include <config.h>
 
+#define SAVEWD_INLINE _GL_EXTERN_INLINE
+
 #include "savewd.h"
 
 #include <assert.h>
@@ -254,7 +256,7 @@
    This is why savewd_chdir is broken out into another function;
    savewd_chdir's callers _can_ inspect the file system to decide
    whether to call savewd_chdir.  */
-static inline bool
+static bool
 savewd_delegating (struct savewd const *wd)
 {
   return wd->state == FORKING_STATE && 0 < wd->val.child;