aboutsummaryrefslogtreecommitdiffstats
path: root/src/buffer.h
diff options
context:
space:
mode:
authorStefan Monnier2007-11-21 20:59:47 +0000
committerStefan Monnier2007-11-21 20:59:47 +0000
commit64e16c3c22db9f01922a4f3efb936c4265ccec7a (patch)
tree62cd4f172cedd91260805d9b9951918141dbbe43 /src/buffer.h
parentcb01ce3f055a415bbe4f2be4fbd0e4a7f320d688 (diff)
downloademacs-64e16c3c22db9f01922a4f3efb936c4265ccec7a.tar.gz
emacs-64e16c3c22db9f01922a4f3efb936c4265ccec7a.zip
* lisp.h (struct Lisp_Buffer_Objfwd): Add a `slottype' field.
* data.c (store_symval_forwarding): Get type from buffer_objfwd. Update call to buffer_slot_type_mismatch. * buffer.h (buffer_local_types, PER_BUFFER_TYPE): Remove. (buffer_slot_type_mismatch): Update. * buffer.c (buffer_local_types): Remove. (buffer_slot_type_mismatch): Get the symbol and type as arguments. (defvar_per_buffer): Set the type in the buffer_objfwd.
Diffstat (limited to 'src/buffer.h')
-rw-r--r--src/buffer.h20
1 files changed, 1 insertions, 19 deletions
diff --git a/src/buffer.h b/src/buffer.h
index 37f499f0351..a308d20e491 100644
--- a/src/buffer.h
+++ b/src/buffer.h
@@ -818,18 +818,6 @@ extern struct buffer buffer_local_flags;
818 that don't have such names. */ 818 that don't have such names. */
819 819
820extern struct buffer buffer_local_symbols; 820extern struct buffer buffer_local_symbols;
821
822/* This structure holds the required types for the values in the
823 buffer-local slots. If a slot contains Qnil, then the
824 corresponding buffer slot may contain a value of any type. If a
825 slot contains an integer, then prospective values' tags must be
826 equal to that integer (except nil is always allowed).
827 When a tag does not match, the function
828 buffer_slot_type_mismatch will signal an error.
829
830 If a slot here contains -1, the corresponding variable is read-only. */
831
832extern struct buffer buffer_local_types;
833 821
834extern void delete_all_overlays P_ ((struct buffer *)); 822extern void delete_all_overlays P_ ((struct buffer *));
835extern void reset_buffer P_ ((struct buffer *)); 823extern void reset_buffer P_ ((struct buffer *));
@@ -843,7 +831,7 @@ extern void set_buffer_internal P_ ((struct buffer *));
843extern void set_buffer_internal_1 P_ ((struct buffer *)); 831extern void set_buffer_internal_1 P_ ((struct buffer *));
844extern void set_buffer_temp P_ ((struct buffer *)); 832extern void set_buffer_temp P_ ((struct buffer *));
845extern void record_buffer P_ ((Lisp_Object)); 833extern void record_buffer P_ ((Lisp_Object));
846extern void buffer_slot_type_mismatch P_ ((int)) NO_RETURN; 834extern void buffer_slot_type_mismatch P_ ((Lisp_Object, int)) NO_RETURN;
847extern void fix_overlays_before P_ ((struct buffer *, EMACS_INT, EMACS_INT)); 835extern void fix_overlays_before P_ ((struct buffer *, EMACS_INT, EMACS_INT));
848extern void mmap_set_vars P_ ((int)); 836extern void mmap_set_vars P_ ((int));
849 837
@@ -995,11 +983,5 @@ extern int last_per_buffer_idx;
995#define PER_BUFFER_SYMBOL(OFFSET) \ 983#define PER_BUFFER_SYMBOL(OFFSET) \
996 (*(Lisp_Object *)((OFFSET) + (char *) &buffer_local_symbols)) 984 (*(Lisp_Object *)((OFFSET) + (char *) &buffer_local_symbols))
997 985
998/* Return the type of the per-buffer variable at offset OFFSET in the
999 buffer structure. */
1000
1001#define PER_BUFFER_TYPE(OFFSET) \
1002 (*(Lisp_Object *)((OFFSET) + (char *) &buffer_local_types))
1003
1004/* arch-tag: 679305dd-d41c-4a50-b170-3caf5c97b2d1 986/* arch-tag: 679305dd-d41c-4a50-b170-3caf5c97b2d1
1005 (do not change this comment) */ 987 (do not change this comment) */