1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-20 11:40:18 +02:00

Restore libgc 7.2 compatibility

* configure.ac: Check for GC_is_heap_ptr, added after libgc 7.2.
* libguile/pairs.h (GC_is_heap_ptr): Define a shim for GC_is_heap_ptr,
  inside BUILDING_LIBGUILE so as not to expose it to users.
This commit is contained in:
Andy Wingo 2017-04-20 10:40:07 +02:00
parent 3db21f5eb9
commit 40df57a8a2
2 changed files with 9 additions and 1 deletions

View file

@ -1346,7 +1346,7 @@ CFLAGS="$BDW_GC_CFLAGS $CFLAGS"
AC_CHECK_FUNCS([GC_pthread_exit GC_pthread_cancel GC_pthread_sigmask])
# Functions from GC 7.3.
AC_CHECK_FUNCS([GC_move_disappearing_link])
AC_CHECK_FUNCS([GC_move_disappearing_link GC_is_heap_ptr])
LIBS="$save_LIBS"

View file

@ -177,6 +177,14 @@ scm_cdr (SCM x)
#endif
#ifdef BUILDING_LIBGUILE
#ifndef HAVE_GC_IS_HEAP_PTR
static int
GC_is_heap_ptr (void *ptr)
{
return GC_base (ptr) != NULL;
}
#endif
static inline int
scm_is_mutable_pair (SCM x)
{