mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-09 23:40:29 +02:00
* Deprecated some unused SCM_NxxxP macros.
* Removed conditionally compiled code depending on 'nosve'.
This commit is contained in:
parent
fe517a7d3d
commit
6ba93e5e88
6 changed files with 38 additions and 34 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
2000-05-23 Dirk Herrmann <D.Herrmann@tu-bs.de>
|
||||||
|
|
||||||
|
* strings.h (SCM_NSTRINGP, SCM_NRWSTRINGP), tags.h
|
||||||
|
(SCM_NDOUBLE_CELLP), vectors.h (SCM_NVECTORP): Deprecated.
|
||||||
|
|
||||||
|
* gc.c (scm_igc), gc.h (SCM_PTR_MASK, SCM_PTR_LT): Removed #ifdef
|
||||||
|
nosve #endif conditionally compiled code.
|
||||||
|
|
||||||
2000-05-23 Michael Livshin <mlivshin@bigfoot.com>
|
2000-05-23 Michael Livshin <mlivshin@bigfoot.com>
|
||||||
|
|
||||||
* gc.c (scm_heap_seg_data_t): fixed comment for the `span' member.
|
* gc.c (scm_heap_seg_data_t): fixed comment for the `span' member.
|
||||||
|
|
|
@ -860,22 +860,11 @@ scm_igc (const char *what)
|
||||||
/ sizeof (SCM_STACKITEM)));
|
/ sizeof (SCM_STACKITEM)));
|
||||||
|
|
||||||
{
|
{
|
||||||
/* stack_len is long rather than scm_sizet in order to guarantee that
|
scm_sizet stack_len = scm_stack_size (scm_stack_base);
|
||||||
&stack_len is long aligned */
|
|
||||||
#ifdef SCM_STACK_GROWS_UP
|
#ifdef SCM_STACK_GROWS_UP
|
||||||
#ifdef nosve
|
scm_mark_locations (scm_stack_base, stack_len);
|
||||||
long stack_len = (SCM_STACKITEM *) (&stack_len) - scm_stack_base;
|
|
||||||
#else
|
#else
|
||||||
long stack_len = scm_stack_size (scm_stack_base);
|
scm_mark_locations (scm_stack_base - stack_len, stack_len);
|
||||||
#endif
|
|
||||||
scm_mark_locations (scm_stack_base, (scm_sizet) stack_len);
|
|
||||||
#else
|
|
||||||
#ifdef nosve
|
|
||||||
long stack_len = scm_stack_base - (SCM_STACKITEM *) (&stack_len);
|
|
||||||
#else
|
|
||||||
long stack_len = scm_stack_size (scm_stack_base);
|
|
||||||
#endif
|
|
||||||
scm_mark_locations ((scm_stack_base - stack_len), (scm_sizet) stack_len);
|
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -137,18 +137,11 @@ typedef scm_cell * SCM_CELLPTR;
|
||||||
#define SCM_CDRLOC(x) (&SCM_CDR (x))
|
#define SCM_CDRLOC(x) (&SCM_CDR (x))
|
||||||
|
|
||||||
|
|
||||||
/* SCM_PTR_LT defines how to compare two SCM_CELLPTRs (which may not be in the
|
/* SCM_PTR_LT and friends define how to compare two SCM_CELLPTRs (which may
|
||||||
* same scm_array).
|
* point to cells in different heap segments).
|
||||||
*/
|
*/
|
||||||
|
#define SCM_PTR_LT(x, y) ((x) < (y))
|
||||||
#ifdef nosve
|
#define SCM_PTR_GT(x, y) (SCM_PTR_LT (y, x))
|
||||||
#define SCM_PTR_MASK 0xffffffffffff
|
|
||||||
#define SCM_PTR_LT(x, y) (((int) (x) & SCM_PTR_MASK) < ((int) (y) & SCM_PTR_MASK))
|
|
||||||
#else
|
|
||||||
#define SCM_PTR_LT(x, y) ((x) < (y))
|
|
||||||
#endif /* def nosve */
|
|
||||||
|
|
||||||
#define SCM_PTR_GT(x, y) SCM_PTR_LT (y, x)
|
|
||||||
#define SCM_PTR_LE(x, y) (!SCM_PTR_GT (x, y))
|
#define SCM_PTR_LE(x, y) (!SCM_PTR_GT (x, y))
|
||||||
#define SCM_PTR_GE(x, y) (!SCM_PTR_LT (x, y))
|
#define SCM_PTR_GE(x, y) (!SCM_PTR_LT (x, y))
|
||||||
|
|
||||||
|
|
|
@ -51,17 +51,14 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define SCM_SLOPPY_STRINGP(x) (SCM_TYP7S(x)==scm_tc7_string)
|
#define SCM_SLOPPY_STRINGP(x) (SCM_TYP7S (x) == scm_tc7_string)
|
||||||
#define SCM_STRINGP(x) (SCM_NIMP(x) && SCM_SLOPPY_STRINGP(x))
|
#define SCM_STRINGP(x) (SCM_NIMP (x) && SCM_SLOPPY_STRINGP (x))
|
||||||
#define SCM_NSTRINGP(x) (!SCM_STRINGP(x))
|
|
||||||
|
|
||||||
/* Is X a writable string (i.e., not a substring)? */
|
/* Is X a writable string (i.e., not a substring)? */
|
||||||
#define SCM_RWSTRINGP(x) (SCM_NIMP(x) && (SCM_TYP7(x) == scm_tc7_string))
|
#define SCM_RWSTRINGP(x) (SCM_NIMP (x) && (SCM_TYP7 (x) == scm_tc7_string))
|
||||||
#define SCM_NRWSTRINGP(x) (! SCM_RWSTRINGP (x))
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
extern SCM scm_string_p (SCM x);
|
extern SCM scm_string_p (SCM x);
|
||||||
extern SCM scm_read_only_string_p (SCM x);
|
extern SCM scm_read_only_string_p (SCM x);
|
||||||
extern SCM scm_string (SCM chrs);
|
extern SCM scm_string (SCM chrs);
|
||||||
|
@ -81,6 +78,15 @@ extern SCM scm_string_append (SCM args);
|
||||||
extern SCM scm_make_shared_substring (SCM str, SCM frm, SCM to);
|
extern SCM scm_make_shared_substring (SCM str, SCM frm, SCM to);
|
||||||
extern void scm_init_strings (void);
|
extern void scm_init_strings (void);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#if (SCM_DEBUG_DEPRECATED == 0)
|
||||||
|
|
||||||
|
#define SCM_NSTRINGP(x) (!SCM_STRINGP(x))
|
||||||
|
#define SCM_NRWSTRINGP(x) (! SCM_RWSTRINGP (x))
|
||||||
|
|
||||||
|
#endif /* SCM_DEBUG_DEPRECATED == 0 */
|
||||||
|
|
||||||
#endif /* STRINGSH */
|
#endif /* STRINGSH */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -306,8 +306,7 @@ typedef long scm_bits_t;
|
||||||
#define SCM_CELLP(x) (!SCM_NCELLP (x))
|
#define SCM_CELLP(x) (!SCM_NCELLP (x))
|
||||||
#define SCM_NCELLP(x) ((sizeof (scm_cell) - 1) & SCM_UNPACK (x))
|
#define SCM_NCELLP(x) ((sizeof (scm_cell) - 1) & SCM_UNPACK (x))
|
||||||
|
|
||||||
#define SCM_DOUBLE_CELLP(x) (!SCM_NDOUBLE_CELLP (x))
|
#define SCM_DOUBLE_CELLP(x) (((2 * sizeof (scm_cell) - 1) & SCM_UNPACK (x)) == 0)
|
||||||
#define SCM_NDOUBLE_CELLP(x) ((2 * sizeof (scm_cell) - 1) & SCM_UNPACK (x))
|
|
||||||
|
|
||||||
/* See numbers.h for macros relating to immediate integers.
|
/* See numbers.h for macros relating to immediate integers.
|
||||||
*/
|
*/
|
||||||
|
@ -581,6 +580,8 @@ extern char *scm_isymnames[]; /* defined in print.c */
|
||||||
|
|
||||||
#if (SCM_DEBUG_DEPRECATED == 0)
|
#if (SCM_DEBUG_DEPRECATED == 0)
|
||||||
|
|
||||||
|
#define SCM_NDOUBLE_CELLP(x) (!SCM_DOUBLE_CELLP (x))
|
||||||
|
|
||||||
#define scm_tc16_flo scm_tc16_real
|
#define scm_tc16_flo scm_tc16_real
|
||||||
#define scm_tc_flo 0x017fL
|
#define scm_tc_flo 0x017fL
|
||||||
#define scm_tc_dblr scm_tc16_real
|
#define scm_tc_dblr scm_tc16_real
|
||||||
|
|
|
@ -52,7 +52,6 @@
|
||||||
|
|
||||||
|
|
||||||
#define SCM_VECTORP(x) (SCM_NIMP (x) && (SCM_TYP7S (x) == scm_tc7_vector))
|
#define SCM_VECTORP(x) (SCM_NIMP (x) && (SCM_TYP7S (x) == scm_tc7_vector))
|
||||||
#define SCM_NVECTORP(x) (!SCM_VECTORP (x))
|
|
||||||
#define SCM_VELTS(x) ((SCM *) SCM_CELL_WORD_1 (x))
|
#define SCM_VELTS(x) ((SCM *) SCM_CELL_WORD_1 (x))
|
||||||
#define SCM_VELTS_AS_STACKITEMS(x) ((SCM_STACKITEM *) SCM_CELL_WORD_1 (x))
|
#define SCM_VELTS_AS_STACKITEMS(x) ((SCM_STACKITEM *) SCM_CELL_WORD_1 (x))
|
||||||
#define SCM_SETVELTS(x,v) (SCM_SET_CELL_WORD_1 ((x), (v)))
|
#define SCM_SETVELTS(x,v) (SCM_SET_CELL_WORD_1 ((x), (v)))
|
||||||
|
@ -85,6 +84,14 @@ extern SCM scm_vector_move_right_x (SCM vec1, SCM start1, SCM end1,
|
||||||
SCM vec2, SCM start2);
|
SCM vec2, SCM start2);
|
||||||
extern void scm_init_vectors (void);
|
extern void scm_init_vectors (void);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#if (SCM_DEBUG_DEPRECATED == 0)
|
||||||
|
|
||||||
|
#define SCM_NVECTORP(x) (!SCM_VECTORP (x))
|
||||||
|
|
||||||
|
#endif /* SCM_DEBUG_DEPRECATED == 0 */
|
||||||
|
|
||||||
#endif /* VECTORSH */
|
#endif /* VECTORSH */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue