From f86f3b5b113b4cb383c531150b13bef9b2789221 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Tue, 25 Aug 2009 23:57:49 +0200 Subject: Remove the `scm_tc_free_cell' SMOB type. * libguile/deprecated.h (SCM_FREEP, SCM_NFREEP): Changed to constants. * libguile/gc.c (scm_i_tag_name): Remove reference to `scm_tc_free_cell'. * libguile/gc.h (SCM_FREE_CELL_CDR, SCM_SET_FREE_CELL_CDR): Remove. * libguile/smob.c (free_print): Remove. (scm_smob_prehistory): Don't create the "free" SMOB type. * libguile/struct.c (struct_finalizer_trampoline): Use a bare `scm_tc3_struct' tag for finalized structs instead of `scm_tc_free_cell'. * libguile/tags.h (scm_tc_free_cell): Remove. --- libguile/smob.c | 25 ------------------------- 1 file changed, 25 deletions(-) (limited to 'libguile/smob.c') diff --git a/libguile/smob.c b/libguile/smob.c index b2c083cd3..86bb22f47 100644 --- a/libguile/smob.c +++ b/libguile/smob.c @@ -471,26 +471,6 @@ scm_make_smob (scm_t_bits tc) SCM_RETURN_NEWSMOB (tc, data); } - -/* {Initialization for the type of free cells} - */ - -static int -free_print (SCM exp, SCM port, scm_print_state *pstate SCM_UNUSED) -{ - char buf[100]; - sprintf (buf, "#", - (void *) SCM_UNPACK (exp)); - scm_puts (buf, port); - -#if (SCM_DEBUG_CELL_ACCESSES == 1) - if (scm_debug_cell_accesses_p) - abort(); -#endif - - - return 1; -} /* Marking SMOBs using user-supplied mark procedures. */ @@ -632,7 +612,6 @@ void scm_smob_prehistory () { long i; - scm_t_bits tc; smob_gc_kind = GC_new_kind (GC_new_free_list (), GC_MAKE_PROC (GC_new_proc (smob_mark), 0), @@ -657,10 +636,6 @@ scm_smob_prehistory () scm_smobs[i].apply_3 = 0; scm_smobs[i].gsubr_type = 0; } - - /* WARNING: This scm_make_smob_type call must be done first. */ - tc = scm_make_smob_type ("free", 0); - scm_set_smob_print (tc, free_print); } /* -- cgit v1.2.1