[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] 45/86: Move scm_tc7_pointer snarfer out to foreign.h
From: |
Andy Wingo |
Subject: |
[Guile-commits] 45/86: Move scm_tc7_pointer snarfer out to foreign.h |
Date: |
Wed, 20 Jun 2018 14:09:37 -0400 (EDT) |
wingo pushed a commit to branch master
in repository guile.
commit cedab6e2856db466159b9861963a50d72cbd71d8
Author: Andy Wingo <address@hidden>
Date: Wed Jun 20 08:38:32 2018 +0200
Move scm_tc7_pointer snarfer out to foreign.h
* libguile/snarf.h:
* libguile/foreign.h (SCM_IMMUTABLE_POINTER): Move here, from snarf.h.
---
libguile/foreign.h | 4 ++++
libguile/snarf.h | 3 ---
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/libguile/foreign.h b/libguile/foreign.h
index 3e0312b..b78f29d 100644
--- a/libguile/foreign.h
+++ b/libguile/foreign.h
@@ -21,6 +21,7 @@
#include "libguile/__scm.h"
#include "libguile/gc.h"
+#include "libguile/snarf.h"
/* A "foreign pointer" is a wrapped C pointer. It is represented by a
cell whose second word is a pointer. The first word has the
@@ -55,6 +56,9 @@ typedef void (*scm_t_pointer_finalizer) (void *);
#define SCM_POINTER_VALUE(x) \
((void *) SCM_CELL_WORD_1 (x))
+#define SCM_IMMUTABLE_POINTER(c_name, ptr) \
+ SCM_IMMUTABLE_CELL (c_name, scm_tc7_pointer, ptr)
+
SCM_API void *scm_to_pointer (SCM pointer);
SCM_API SCM scm_from_pointer (void *, scm_t_pointer_finalizer);
diff --git a/libguile/snarf.h b/libguile/snarf.h
index e20ac64..3ef17c1 100644
--- a/libguile/snarf.h
+++ b/libguile/snarf.h
@@ -326,9 +326,6 @@ SCM_SNARF_INIT(scm_set_smob_apply((tag), (c_name), (req),
(opt), (rest));)
(scm_t_bits) 0, \
(scm_t_bits) (sizeof (contents) - 1))
-#define SCM_IMMUTABLE_POINTER(c_name, ptr) \
- SCM_IMMUTABLE_CELL (c_name, scm_tc7_pointer, ptr)
-
#endif /* SCM_SUPPORT_STATIC_ALLOCATION */
- [Guile-commits] 12/86: Remove error.h include from _scm.h., (continued)
- [Guile-commits] 12/86: Remove error.h include from _scm.h., Andy Wingo, 2018/06/20
- [Guile-commits] 20/86: Move pair, null, nil, and boolean validators out of validate.h, Andy Wingo, 2018/06/20
- [Guile-commits] 29/86: Move gsubr.h include to snarf.h, Andy Wingo, 2018/06/20
- [Guile-commits] 33/86: Move array-handle.h include out from inline.h, Andy Wingo, 2018/06/20
- [Guile-commits] 30/86: Devolve procs.h include from _scm.h., Andy Wingo, 2018/06/20
- [Guile-commits] 36/86: Remove threads.h include from ports.h, Andy Wingo, 2018/06/20
- [Guile-commits] 28/86: Devolve gc.h, Andy Wingo, 2018/06/20
- [Guile-commits] 35/86: Move struct.h include out of ports.h, Andy Wingo, 2018/06/20
- [Guile-commits] 34/86: Remove bytevectors.h include form ports.h, Andy Wingo, 2018/06/20
- [Guile-commits] 43/86: Remove error.h from inline.h, Andy Wingo, 2018/06/20
- [Guile-commits] 45/86: Move scm_tc7_pointer snarfer out to foreign.h,
Andy Wingo <=
- [Guile-commits] 46/86: Move symbol snarfers to symbols.h, Andy Wingo, 2018/06/20
- [Guile-commits] 41/86: Remove ports.h from inline.h, Andy Wingo, 2018/06/20
- [Guile-commits] 21/86: More validate.h devolution, Andy Wingo, 2018/06/20
- [Guile-commits] 40/86: Remove <unistd.h> from ports.h, Andy Wingo, 2018/06/20
- [Guile-commits] 37/86: Devolve vectors.h include from ports.h, Andy Wingo, 2018/06/20
- [Guile-commits] 38/86: Remove <string.h> include from ports.h., Andy Wingo, 2018/06/20
- [Guile-commits] 42/86: Remove numbers.h from inline.h, Andy Wingo, 2018/06/20
- [Guile-commits] 48/86: Deprecate SCM_STATIC_DOUBLE_CELL snarf macro, Andy Wingo, 2018/06/20
- [Guile-commits] 51/86: Devolve variable snarfers, Andy Wingo, 2018/06/20
- [Guile-commits] 50/86: Devolve keyword-snarfing macros, Andy Wingo, 2018/06/20