Mercurial > hg > xemacs-beta
comparison src/unicode.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 | b7f26b2f78bd |
comparison
equal
deleted
inserted
replaced
3016:f252275fb013 | 3017:1e7cc382eb16 |
---|---|
546 } | 546 } |
547 break; | 547 break; |
548 } | 548 } |
549 } | 549 } |
550 | 550 |
551 #ifdef MC_ALLOC | 551 size += MALLOCED_STORAGE_SIZE (table, |
552 size += mc_alloced_storage_size (256 * (level == 1 ? sizeof (short) : | |
553 sizeof (void *)), stats); | |
554 #else /* not MC_ALLOC */ | |
555 size += malloced_storage_size (table, | |
556 256 * (level == 1 ? sizeof (short) : | 552 256 * (level == 1 ? sizeof (short) : |
557 sizeof (void *)), | 553 sizeof (void *)), |
558 stats); | 554 stats); |
559 #endif /* not MC_ALLOC */ | |
560 return size; | 555 return size; |
561 } | 556 } |
562 | 557 |
563 static Bytecount | 558 static Bytecount |
564 compute_to_unicode_table_size_1 (void *table, int level, | 559 compute_to_unicode_table_size_1 (void *table, int level, |
576 if (tab[i] != to_unicode_blank_1) | 571 if (tab[i] != to_unicode_blank_1) |
577 size += compute_to_unicode_table_size_1 (tab[i], 1, stats); | 572 size += compute_to_unicode_table_size_1 (tab[i], 1, stats); |
578 } | 573 } |
579 } | 574 } |
580 | 575 |
581 #ifdef MC_ALLOC | 576 size += MALLOCED_STORAGE_SIZE (table, |
582 size += mc_alloced_storage_size (96 * (level == 1 ? sizeof (int) : | |
583 sizeof (void *)), stats); | |
584 #else /* not MC_ALLOC */ | |
585 size += malloced_storage_size (table, | |
586 96 * (level == 1 ? sizeof (int) : | 577 96 * (level == 1 ? sizeof (int) : |
587 sizeof (void *)), | 578 sizeof (void *)), |
588 stats); | 579 stats); |
589 #endif /* not MC_ALLOC */ | |
590 return size; | 580 return size; |
591 } | 581 } |
592 | 582 |
593 Bytecount | 583 Bytecount |
594 compute_from_unicode_table_size (Lisp_Object charset, | 584 compute_from_unicode_table_size (Lisp_Object charset, |