diff options
| author | Stefan Monnier | 2014-04-07 12:08:46 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2014-04-07 12:08:46 -0400 |
| commit | e3b838807bf9fbbbec9826de6c1e4efdf72acb78 (patch) | |
| tree | af955b069b9dab5d52cfed618cf1f2f7cffa40f5 /src/lisp.h | |
| parent | 190f899aed4eeb62286874bda47a92236d52ad4c (diff) | |
| download | emacs-e3b838807bf9fbbbec9826de6c1e4efdf72acb78.tar.gz emacs-e3b838807bf9fbbbec9826de6c1e4efdf72acb78.zip | |
* src/alloc.c: Keep track of symbols referenced from pure space (bug#17168).
(symbol_block_pinned): New var.
(Fmake_symbol): Initialize `pinned'.
(purecopy): New function, extracted from Fpurecopy. Mark symbols as
pinned and signal an error for un-purifiable objects.
(pure_cons): Use it.
(Fpurecopy): Use it, except for objects that can't be purified.
(mark_pinned_symbols): New function.
(Fgarbage_collect): Use it.
(gc_sweep): Remove hack made unnecessary.
* src/lisp.h (struct Lisp_Symbol): New bitfield `pinned'.
Diffstat (limited to 'src/lisp.h')
| -rw-r--r-- | src/lisp.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lisp.h b/src/lisp.h index 30f52b9070c..ea294f8d1da 100644 --- a/src/lisp.h +++ b/src/lisp.h | |||
| @@ -1568,6 +1568,9 @@ struct Lisp_Symbol | |||
| 1568 | special (with `defvar' etc), and shouldn't be lexically bound. */ | 1568 | special (with `defvar' etc), and shouldn't be lexically bound. */ |
| 1569 | bool_bf declared_special : 1; | 1569 | bool_bf declared_special : 1; |
| 1570 | 1570 | ||
| 1571 | /* True if pointed to from purespace and hence can't be GC'd. */ | ||
| 1572 | bool_bf pinned : 1; | ||
| 1573 | |||
| 1571 | /* The symbol's name, as a Lisp string. */ | 1574 | /* The symbol's name, as a Lisp string. */ |
| 1572 | Lisp_Object name; | 1575 | Lisp_Object name; |
| 1573 | 1576 | ||