Index: data.c =================================================================== RCS file: /usr/CVSroot/XEmacs/xemacs/src/data.c,v retrieving revision 1.24.2.16 diff -u -r1.24.2.16 data.c --- data.c 2000/04/02 12:38:36 1.24.2.16 +++ data.c 2000/05/29 14:11:22 @@ -1744,6 +1744,23 @@ } break; + case WEAK_LIST_FULL_ASSOC: + if (!CONSP (elem)) + { + /* just leave bogus elements there */ + need_to_mark_cons = 1; + need_to_mark_elem = 1; + } + else if (marked_p (XCAR (elem)) || + marked_p (XCDR (elem))) + { + need_to_mark_cons = 1; + /* We still need to mark elem and XCAR (elem); + marking elem does both */ + need_to_mark_elem = 1; + } + break; + default: abort (); } @@ -1884,6 +1901,7 @@ if (EQ (symbol, Qold_assoc)) return WEAK_LIST_ASSOC; /* EBOLA ALERT! */ if (EQ (symbol, Qkey_assoc)) return WEAK_LIST_KEY_ASSOC; if (EQ (symbol, Qvalue_assoc)) return WEAK_LIST_VALUE_ASSOC; + if (EQ (symbol, Qfull_assoc)) return WEAK_LIST_FULL_ASSOC; signal_simple_error ("Invalid weak list type", symbol); return WEAK_LIST_SIMPLE; /* not reached */ @@ -1898,6 +1916,7 @@ case WEAK_LIST_ASSOC: return Qassoc; case WEAK_LIST_KEY_ASSOC: return Qkey_assoc; case WEAK_LIST_VALUE_ASSOC: return Qvalue_assoc; + case WEAK_LIST_FULL_ASSOC: return Qfull_assoc; default: abort (); } @@ -1936,6 +1955,8 @@ and the car is not pointed to. `value-assoc' Objects in the list disappear if they are conses and the cdr is not pointed to. +`full-assoc' Objects in the list disappear if they are conses + and neither the car nor the cdr is pointed to. */ (type)) { Index: general.c =================================================================== RCS file: /usr/CVSroot/XEmacs/xemacs/src/general.c,v retrieving revision 1.13.2.13 diff -u -r1.13.2.13 general.c --- general.c 2000/05/11 10:29:35 1.13.2.13 +++ general.c 2000/05/29 14:11:22 @@ -84,6 +84,7 @@ Lisp_Object Qfile_name; Lisp_Object Qfont; Lisp_Object Qframe; +Lisp_Object Qfull_assoc; Lisp_Object Qfuncall; Lisp_Object Qfunction; Lisp_Object Qgap_overhead; @@ -250,6 +251,7 @@ defsymbol (&Qfile_name, "file-name"); defsymbol (&Qfont, "font"); defsymbol (&Qframe, "frame"); + defsymbol (&Qfull_assoc, "full-assoc"); defsymbol (&Qfuncall, "funcall"); defsymbol (&Qfunction, "function"); defsymbol (&Qgap_overhead, "gap-overhead"); Index: lisp.h =================================================================== RCS file: /usr/CVSroot/XEmacs/xemacs/src/lisp.h,v retrieving revision 1.38.2.64 diff -u -r1.38.2.64 lisp.h --- lisp.h 2000/05/21 01:40:39 1.38.2.64 +++ lisp.h 2000/05/29 14:11:22 @@ -1388,7 +1388,10 @@ /* element disappears if it's a cons and its car is unmarked. */ WEAK_LIST_KEY_ASSOC, /* element disappears if it's a cons and its cdr is unmarked. */ - WEAK_LIST_VALUE_ASSOC + WEAK_LIST_VALUE_ASSOC, + /* element disappears if it's a cons and neither its car nor + its cdr is marked. */ + WEAK_LIST_FULL_ASSOC }; struct weak_list @@ -2826,7 +2829,7 @@ extern Lisp_Object Qfile_name, Qfile_error; extern Lisp_Object Qfont, Qforce_g0_on_output, Qforce_g1_on_output; extern Lisp_Object Qforce_g2_on_output, Qforce_g3_on_output, Qforeground; -extern Lisp_Object Qformat, Qframe, Qframe_live_p, Qfuncall, Qfunction; +extern Lisp_Object Qformat, Qframe, Qframe_live_p, Qfull_assoc, Qfuncall, Qfunction; extern Lisp_Object Qgap_overhead, Qgeneric, Qgeometry, Qglobal, Qheight; extern Lisp_Object Qhelp, Qhighlight, Qhorizontal, Qicon; extern Lisp_Object Qicon_glyph_p, Qid, Qidentity, Qignore, Qimage, Qinfo;