summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@edwardthomson.com>2021-07-30 08:34:28 -0400
committerGitHub <noreply@github.com>2021-07-30 08:34:28 -0400
commit708d9336bb677320e975936e251c7eacf5661510 (patch)
treedc7796c6d6b7fecdebb4ca9dfb6210dd4921aa9c
parent003a1df6540c9f24042e496b64b87223dff29cf0 (diff)
parent88a3b8e1c863cea01a625a6f41205a306c2cccd2 (diff)
downloadlibgit2-708d9336bb677320e975936e251c7eacf5661510.tar.gz
Merge pull request #5953 from boretrk/c99-inline
common.h: use inline when compiling for C99 and later
-rw-r--r--src/common.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/common.h b/src/common.h
index 9123fb595..f83eeb69e 100644
--- a/src/common.h
+++ b/src/common.h
@@ -19,6 +19,8 @@
# define GIT_INLINE(type) static __inline type
#elif defined(__GNUC__)
# define GIT_INLINE(type) static __inline__ type
+#elif defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L)
+# define GIT_INLINE(type) static inline type
#else
# define GIT_INLINE(type) static type
#endif