Mercurial > hg > xemacs-beta
comparison src/data.c @ 3017:1e7cc382eb16
[xemacs-hg @ 2005-10-24 10:07:26 by ben]
refactor mc-alloc dependencies
next-error.el, occur.el: Fix some byte-compile warnings.
alloc.c, buffer.c, buffer.h, casetab.c, casetab.h, charset.h, chartab.c, chartab.h, console-impl.h, console-msw-impl.h, console.c, data.c, database.c, device-impl.h, device-msw.c, device.c, dialog-msw.c, elhash.c, events.h, extents-impl.h, extents.c, faces.c, faces.h, file-coding.c, file-coding.h, frame-impl.h, frame.c, glyphs.c, glyphs.h, gui.c, gui.h, keymap.c, lisp.h, lrecord.h, lstream.c, lstream.h, mule-charset.c, objects-impl.h, objects.c, opaque.c, opaque.h, print.c, process.c, procimpl.h, rangetab.c, rangetab.h, scrollbar-gtk.c, scrollbar-msw.c, scrollbar-x.c, scrollbar.c, scrollbar.h, specifier.c, specifier.h, symbols.c, symeval.h, toolbar.c, toolbar.h, tooltalk.c, ui-gtk.c, ui-gtk.h, unicode.c, window-impl.h, window.c:
Eliminate the majority of #ifdef MC_ALLOC occurrences through
macros LCRECORD_HEADER, ALLOC_LCRECORD_TYPE, MALLOCED_STORAGE_SIZE,
etc. (defined in lrecord.h).
author | ben |
---|---|
date | Mon, 24 Oct 2005 10:07:42 +0000 |
parents | 6fa9919a9a0b |
children | 29234c1a76c7 3742ea8250b5 |
comparison
equal
deleted
inserted
replaced
3016:f252275fb013 | 3017:1e7cc382eb16 |
---|---|
2575 Lisp_Object | 2575 Lisp_Object |
2576 make_weak_list (enum weak_list_type type) | 2576 make_weak_list (enum weak_list_type type) |
2577 { | 2577 { |
2578 Lisp_Object result; | 2578 Lisp_Object result; |
2579 struct weak_list *wl = | 2579 struct weak_list *wl = |
2580 #ifdef MC_ALLOC | 2580 ALLOC_LCRECORD_TYPE (struct weak_list, &lrecord_weak_list); |
2581 alloc_lrecord_type (struct weak_list, &lrecord_weak_list); | |
2582 #else /* not MC_ALLOC */ | |
2583 alloc_lcrecord_type (struct weak_list, &lrecord_weak_list); | |
2584 #endif /* not MC_ALLOC */ | |
2585 | 2581 |
2586 wl->list = Qnil; | 2582 wl->list = Qnil; |
2587 wl->type = type; | 2583 wl->type = type; |
2588 result = wrap_weak_list (wl); | 2584 result = wrap_weak_list (wl); |
2589 wl->next_weak = Vall_weak_lists; | 2585 wl->next_weak = Vall_weak_lists; |
3054 make_weak_box (Lisp_Object value) | 3050 make_weak_box (Lisp_Object value) |
3055 { | 3051 { |
3056 Lisp_Object result; | 3052 Lisp_Object result; |
3057 | 3053 |
3058 struct weak_box *wb = | 3054 struct weak_box *wb = |
3059 #ifdef MC_ALLOC | 3055 ALLOC_LCRECORD_TYPE (struct weak_box, &lrecord_weak_box); |
3060 alloc_lrecord_type (struct weak_box, &lrecord_weak_box); | |
3061 #else /* not MC_ALLOC */ | |
3062 alloc_lcrecord_type (struct weak_box, &lrecord_weak_box); | |
3063 #endif /* not MC_ALLOC */ | |
3064 | 3056 |
3065 wb->value = value; | 3057 wb->value = value; |
3066 result = wrap_weak_box (wb); | 3058 result = wrap_weak_box (wb); |
3067 wb->next_weak_box = Vall_weak_boxes; | 3059 wb->next_weak_box = Vall_weak_boxes; |
3068 Vall_weak_boxes = result; | 3060 Vall_weak_boxes = result; |
3281 { | 3273 { |
3282 Lisp_Object result, temp = Qnil; | 3274 Lisp_Object result, temp = Qnil; |
3283 struct gcpro gcpro1, gcpro2; | 3275 struct gcpro gcpro1, gcpro2; |
3284 | 3276 |
3285 struct ephemeron *eph = | 3277 struct ephemeron *eph = |
3286 #ifdef MC_ALLOC | 3278 ALLOC_LCRECORD_TYPE (struct ephemeron, &lrecord_ephemeron); |
3287 alloc_lrecord_type (struct ephemeron, &lrecord_ephemeron); | |
3288 #else /* not MC_ALLOC */ | |
3289 alloc_lcrecord_type (struct ephemeron, &lrecord_ephemeron); | |
3290 #endif /* not MC_ALLOC */ | |
3291 | 3279 |
3292 eph->key = Qnil; | 3280 eph->key = Qnil; |
3293 eph->cons_chain = Qnil; | 3281 eph->cons_chain = Qnil; |
3294 eph->value = Qnil; | 3282 eph->value = Qnil; |
3295 | 3283 |