1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-09 13:30:26 +02:00

remove CELL_P macro

* libguile/private-gc.h: Remove private CELL_P macro.
This commit is contained in:
Andy Wingo 2011-10-24 18:28:24 +02:00
parent 47ed8656db
commit cf4c26625b

View file

@ -1,7 +1,7 @@
/*
* private-gc.h - private declarations for garbage collection.
*
* Copyright (C) 2002, 03, 04, 05, 06, 07, 08, 09 Free Software Foundation, Inc.
* Copyright (C) 2002, 03, 04, 05, 06, 07, 08, 09, 11 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
@ -49,18 +49,6 @@ typedef enum { return_on_error, abort_on_error } policy_on_error;
#define SCM_MAX(A, B) ((A) > (B) ? (A) : (B))
#define SCM_MIN(A, B) ((A) < (B) ? (A) : (B))
/* CELL_P checks a random word whether it has the right form for a
pointer to a cell. Use scm_i_find_heap_segment_containing_object
to find out whether it actually points to a real cell.
The right form for a cell pointer is this: the low three bits must
be scm_tc3_cons, and when the scm_tc3_cons tag is stripped, the
resulting pointer must be correctly aligned.
scm_i_initialize_heap_segment_data guarantees that the test below
works.
*/
#define CELL_P(x) ((SCM_UNPACK(x) & (sizeof(scm_t_cell)-1)) == scm_tc3_cons)
SCM_INTERNAL char const *scm_i_tag_name (scm_t_bits tag); /* MOVEME */
#endif