mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-29 16:41:45 -08:00
More GC assertions
This commit is contained in:
commit
a237d879b9
2 changed files with 8 additions and 0 deletions
|
|
@ -1,5 +1,9 @@
|
|||
2014-04-08 Daniel Colascione <dancol@dancol.org>
|
||||
|
||||
* alloc.c (sweep_symbols, mark_object): Assert that symbol
|
||||
function cells contain valid lisp objects. (Modified version of
|
||||
patch from Dmitry).
|
||||
|
||||
* alloc.c (detect_suspicious_free): Split actual stack capturing
|
||||
out into new function for easier breakpoint setting.
|
||||
(note_suspicious_free): New function.
|
||||
|
|
|
|||
|
|
@ -6220,6 +6220,8 @@ mark_object (Lisp_Object arg)
|
|||
break;
|
||||
CHECK_ALLOCATED_AND_LIVE (live_symbol_p);
|
||||
ptr->gcmarkbit = 1;
|
||||
/* Attempt to catch bogus objects. */
|
||||
eassert (valid_lisp_object_p (ptr->function) >= 1);
|
||||
mark_object (ptr->function);
|
||||
mark_object (ptr->plist);
|
||||
switch (ptr->redirect)
|
||||
|
|
@ -6640,6 +6642,8 @@ sweep_symbols (void)
|
|||
{
|
||||
++num_used;
|
||||
sym->s.gcmarkbit = 0;
|
||||
/* Attempt to catch bogus objects. */
|
||||
eassert (valid_lisp_object_p (sym->s.function) >= 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue