Really fix inline machinery for MacOS X.
authorLudovic Courtès <ludo@gnu.org>
Sun, 13 Apr 2008 17:35:46 +0000 (19:35 +0200)
committerLudovic Courtès <ludo@gnu.org>
Sun, 13 Apr 2008 17:39:03 +0000 (19:39 +0200)
libguile/ChangeLog
libguile/inline.h

index 2b471c4..6a90c5e 100644 (file)
@@ -1,3 +1,9 @@
+2008-04-13  Ludovic Courtès  <ludo@gnu.org>
+
+       * inline.h (SCM_C_USE_EXTERN_INLINE): New macro.  Use it to make
+       sure "extern" declarations are produced when "extern inline" is
+       used.
+
 2008-04-10  Ludovic Courtès  <ludo@gnu.org>
 
        * inline.h (SCM_C_EXTERN_INLINE): Special-case Apple's GCC
index 34bb843..904ec50 100644 (file)
@@ -55,6 +55,7 @@
    inline" in that case.  */
 
 # if (defined __GNUC__) && (!(__APPLE_CC__ > 5400 && __STDC_VERSION__ >= 199901L))
+#  define SCM_C_USE_EXTERN_INLINE 1
 #  if (defined __GNUC_STDC_INLINE__) || (__GNUC__ == 4 && __GNUC_MINOR__ == 2)
 #   define SCM_C_EXTERN_INLINE                                 \
            extern __inline__ __attribute__ ((__gnu_inline__))
 #endif /* SCM_INLINE_C_INCLUDING_INLINE_H */
 
 
-#if ((!defined SCM_C_INLINE) && (!defined SCM_INLINE_C_INCLUDING_INLINE_H)) \
-     || (defined __GNUC__)
+#if (!defined SCM_C_INLINE) || (defined SCM_INLINE_C_INCLUDING_INLINE_H) \
+    || (defined SCM_C_USE_EXTERN_INLINE)
 
 /* The `extern' declarations.  They should only appear when used from
-   "inline.c", when `inline' is not supported at all or when GCC's "extern
-   inline" is used.  */
+   "inline.c", when `inline' is not supported at all or when "extern inline"
+   is used.  */
 
 SCM_API SCM scm_cell (scm_t_bits car, scm_t_bits cdr);
 SCM_API SCM scm_double_cell (scm_t_bits car, scm_t_bits cbr,