aboutsummaryrefslogtreecommitdiffstats
path: root/src/alloc.c
diff options
context:
space:
mode:
authorStephen Berman2013-06-21 20:37:42 +0200
committerStephen Berman2013-06-21 20:37:42 +0200
commit716b665eb3a134a5d1ccefd5d4c735e7e7ef62d5 (patch)
treeede9da164267b968f3c05e0340ba12e06b8d3516 /src/alloc.c
parentebc83885b750d46eb290192ae25f6b9a92bdd15f (diff)
parentcad5d1cb5af7210154814b60825576d14740158f (diff)
downloademacs-716b665eb3a134a5d1ccefd5d4c735e7e7ef62d5.tar.gz
emacs-716b665eb3a134a5d1ccefd5d4c735e7e7ef62d5.zip
Merge from trunk.
Diffstat (limited to 'src/alloc.c')
-rw-r--r--src/alloc.c22
1 files changed, 15 insertions, 7 deletions
diff --git a/src/alloc.c b/src/alloc.c
index cce0fff4fd4..d277dd2419b 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -363,6 +363,11 @@ static void *pure_alloc (size_t, int);
363 ((void *) (((uintptr_t) (ptr) + (ALIGNMENT) - 1) \ 363 ((void *) (((uintptr_t) (ptr) + (ALIGNMENT) - 1) \
364 & ~ ((ALIGNMENT) - 1))) 364 & ~ ((ALIGNMENT) - 1)))
365 365
366static void
367XFLOAT_INIT (Lisp_Object f, double n)
368{
369 XFLOAT (f)->u.data = n;
370}
366 371
367 372
368/************************************************************************ 373/************************************************************************
@@ -3189,6 +3194,12 @@ static int symbol_block_index = SYMBOL_BLOCK_SIZE;
3189 3194
3190static struct Lisp_Symbol *symbol_free_list; 3195static struct Lisp_Symbol *symbol_free_list;
3191 3196
3197static void
3198set_symbol_name (Lisp_Object sym, Lisp_Object name)
3199{
3200 XSYMBOL (sym)->name = name;
3201}
3202
3192DEFUN ("make-symbol", Fmake_symbol, Smake_symbol, 1, 1, 0, 3203DEFUN ("make-symbol", Fmake_symbol, Smake_symbol, 1, 1, 0,
3193 doc: /* Return a newly allocated uninterned symbol whose name is NAME. 3204 doc: /* Return a newly allocated uninterned symbol whose name is NAME.
3194Its value is void, and its function definition and property list are nil. */) 3205Its value is void, and its function definition and property list are nil. */)
@@ -3309,7 +3320,7 @@ allocate_misc (enum Lisp_Misc_Type type)
3309 --total_free_markers; 3320 --total_free_markers;
3310 consing_since_gc += sizeof (union Lisp_Misc); 3321 consing_since_gc += sizeof (union Lisp_Misc);
3311 misc_objects_consed++; 3322 misc_objects_consed++;
3312 XMISCTYPE (val) = type; 3323 XMISCANY (val)->type = type;
3313 XMISCANY (val)->gcmarkbit = 0; 3324 XMISCANY (val)->gcmarkbit = 0;
3314 return val; 3325 return val;
3315} 3326}
@@ -3319,7 +3330,7 @@ allocate_misc (enum Lisp_Misc_Type type)
3319void 3330void
3320free_misc (Lisp_Object misc) 3331free_misc (Lisp_Object misc)
3321{ 3332{
3322 XMISCTYPE (misc) = Lisp_Misc_Free; 3333 XMISCANY (misc)->type = Lisp_Misc_Free;
3323 XMISC (misc)->u_free.chain = marker_free_list; 3334 XMISC (misc)->u_free.chain = marker_free_list;
3324 marker_free_list = XMISC (misc); 3335 marker_free_list = XMISC (misc);
3325 consing_since_gc -= sizeof (union Lisp_Misc); 3336 consing_since_gc -= sizeof (union Lisp_Misc);
@@ -5647,7 +5658,7 @@ mark_discard_killed_buffers (Lisp_Object list)
5647 { 5658 {
5648 CONS_MARK (XCONS (tail)); 5659 CONS_MARK (XCONS (tail));
5649 mark_object (XCAR (tail)); 5660 mark_object (XCAR (tail));
5650 prev = &XCDR_AS_LVALUE (tail); 5661 prev = xcdr_addr (tail);
5651 } 5662 }
5652 } 5663 }
5653 mark_object (tail); 5664 mark_object (tail);
@@ -6504,7 +6515,7 @@ bool suppress_checking;
6504void 6515void
6505die (const char *msg, const char *file, int line) 6516die (const char *msg, const char *file, int line)
6506{ 6517{
6507 fprintf (stderr, "\r\n%s:%d: Emacs fatal error: %s\r\n", 6518 fprintf (stderr, "\r\n%s:%d: Emacs fatal error: assertion failed: %s\r\n",
6508 file, line, msg); 6519 file, line, msg);
6509 terminate_due_to_signal (SIGABRT, INT_MAX); 6520 terminate_due_to_signal (SIGABRT, INT_MAX);
6510} 6521}
@@ -6689,8 +6700,5 @@ union
6689 enum MAX_ALLOCA MAX_ALLOCA; 6700 enum MAX_ALLOCA MAX_ALLOCA;
6690 enum More_Lisp_Bits More_Lisp_Bits; 6701 enum More_Lisp_Bits More_Lisp_Bits;
6691 enum pvec_type pvec_type; 6702 enum pvec_type pvec_type;
6692#if USE_LSB_TAG
6693 enum lsb_bits lsb_bits;
6694#endif
6695} const EXTERNALLY_VISIBLE gdb_make_enums_visible = {0}; 6703} const EXTERNALLY_VISIBLE gdb_make_enums_visible = {0};
6696#endif /* __GNUC__ */ 6704#endif /* __GNUC__ */