comparison src/specifier.h @ 771:943eaba38521

[xemacs-hg @ 2002-03-13 08:51:24 by ben] The big ben-mule-21-5 check-in! Various files were added and deleted. See CHANGES-ben-mule. There are still some test suite failures. No crashes, though. Many of the failures have to do with problems in the test suite itself rather than in the actual code. I'll be addressing these in the next day or so -- none of the test suite failures are at all critical. Meanwhile I'll be trying to address the biggest issues -- i.e. build or run failures, which will almost certainly happen on various platforms. All comments should be sent to ben@xemacs.org -- use a Cc: if necessary when sending to mailing lists. There will be pre- and post- tags, something like pre-ben-mule-21-5-merge-in, and post-ben-mule-21-5-merge-in.
author ben
date Wed, 13 Mar 2002 08:54:06 +0000
parents af57a77cbc92
children e38acbeb1cae
comparison
equal deleted inserted replaced
770:336a418893b5 771:943eaba38521
192 192
193 #### Do not still know if this can safely eval. */ 193 #### Do not still know if this can safely eval. */
194 void (*after_change_method) (Lisp_Object specifier, 194 void (*after_change_method) (Lisp_Object specifier,
195 Lisp_Object locale); 195 Lisp_Object locale);
196 196
197 /* Specifier extra data: Specifier objects can have extra data,
198 specific to the type of specifier, stored at the end of the
199 object. To have this, a specifier declares a structure of type
200 `struct TYPE_specifier' containing the data and uses
201 INITIALIZE_SPECIFIER_TYPE_WITH_DATA instead of
202 INITIALIZE_SPECIFIER_TYPE. Then, a pointer to the `struct
203 TYPE_specifier' can be obtained from a specifier object using
204 SPECIFIER_TYPE_DATA. */
205
206 /* Pdump description of the extra data; required, and must be named
207 TYPE_specifier_description. Initialized when
208 INITIALIZE_SPECIFIER_TYPE_WITH_DATA is called. */
197 const struct lrecord_description *extra_description; 209 const struct lrecord_description *extra_description;
210
211 /* Size of extra data structure; initialized when
212 INITIALIZE_SPECIFIER_TYPE_WITH_DATA is called. */
198 int extra_data_size; 213 int extra_data_size;
199 }; 214 };
200 215
201 struct Lisp_Specifier 216 struct Lisp_Specifier
202 { 217 {
299 #endif /* ERROR_CHECK_TYPECHECK */ 314 #endif /* ERROR_CHECK_TYPECHECK */
300 315
301 #define DEFINE_SPECIFIER_TYPE(type) \ 316 #define DEFINE_SPECIFIER_TYPE(type) \
302 struct specifier_methods * type##_specifier_methods 317 struct specifier_methods * type##_specifier_methods
303 318
304 #define INITIALIZE_SPECIFIER_TYPE(type, obj_name, pred_sym) do { \ 319 #define INITIALIZE_SPECIFIER_TYPE(type, obj_name, pred_sym) do { \
305 type##_specifier_methods = xnew_and_zero (struct specifier_methods); \ 320 type##_specifier_methods = xnew_and_zero (struct specifier_methods); \
306 type##_specifier_methods->name = obj_name; \ 321 type##_specifier_methods->name = obj_name; \
307 type##_specifier_methods->extra_description = \ 322 type##_specifier_methods->extra_description = \
308 specifier_empty_extra_description; \ 323 specifier_empty_extra_description; \
309 defsymbol_nodump (&type##_specifier_methods->predicate_symbol, pred_sym); \ 324 defsymbol_nodump (&type##_specifier_methods->predicate_symbol, pred_sym); \
310 add_entry_to_specifier_type_list (Q##type, type##_specifier_methods); \ 325 add_entry_to_specifier_type_list (Q##type, type##_specifier_methods); \
311 dump_add_root_struct_ptr (&type##_specifier_methods, \ 326 dump_add_root_struct_ptr (&type##_specifier_methods, \
312 &specifier_methods_description); \ 327 &specifier_methods_description); \
313 } while (0) 328 } while (0)
314 329
315 #define REINITIALIZE_SPECIFIER_TYPE(type) do { \ 330 #define REINITIALIZE_SPECIFIER_TYPE(type) do { \
316 staticpro_nodump (&type##_specifier_methods->predicate_symbol); \ 331 staticpro_nodump (&type##_specifier_methods->predicate_symbol); \
317 } while (0) 332 } while (0)