1 /*
2  * Motif
3  *
4  * Copyright (c) 1987-2012, The Open Group. All rights reserved.
5  *
6  * These libraries and programs are free software; you can
7  * redistribute them and/or modify them under the terms of the GNU
8  * Lesser General Public License as published by the Free Software
9  * Foundation; either version 2 of the License, or (at your option)
10  * any later version.
11  *
12  * These libraries and programs are distributed in the hope that
13  * they will be useful, but WITHOUT ANY WARRANTY; without even the
14  * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15  * PURPOSE. See the GNU Lesser General Public License for more
16  * details.
17  *
18  * You should have received a copy of the GNU Lesser General Public
19  * License along with these librararies and programs; if not, write
20  * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21  * Floor, Boston, MA 02110-1301 USA
22 */
23 
24 /*
25 **++
26 **  FACILITY:
27 **
28 **      User Interface Language Compiler (UIL)
29 **
30 **  ABSTRACT:
31 **
32 **      This include file defines the set of definitions used by all of
33 **	modules of the UIL compiler.
34 **
35 **--
36 **/
37 
38 #ifndef UilDefI_h
39 #define UilDefI_h
40 
41 
42 /*
43 **
44 **  INCLUDE FILES
45 **
46 **/
47 
48 #define X_INCLUDE_TIME_H
49 #define XOS_USE_XT_LOCKING
50 #ifdef HAVE_X11_XOS_R_H
51 #include <X11/Xos_r.h>
52 #else
53 #include <Xm/Xmos_r.h>
54 #endif
55 
56 #include <Mrm/MrmAppl.h>
57 #include <Mrm/Mrm.h>
58 
59 /*
60 **
61 **  Universal Definitions
62 **
63 */
64 
65 #define _compiler_version "V2.0-000"
66 #define _compiler_version_int 2
67 #define _data_version 2
68 #define _host_compiler "Motif Uil Compiler"
69 
70 #ifdef TRUE
71 #undef TRUE
72 #endif
73 #define TRUE	 	1
74 
75 #ifdef FALSE
76 #undef FALSE
77 #endif
78 #define FALSE	  	0
79 
80 #ifndef debug_version
81 #define debug_version	FALSE
82 #endif
83 
84 #define NOSTRING_DIRECTION 2
85 
86 #define k_normal  	1
87 #define k_error   	0
88 
89 typedef int status;
90 typedef int boolean;
91 
92 /*
93 **  Copy const handling from XmP.h.
94 */
95 
96 #ifndef XmConst
97 #if defined(__STDC__) || !defined( NO_CONST )
98 #define XmConst const
99 #else
100 #define XmConst
101 #endif /* __STDC__ */
102 #endif /* XmConst */
103 
104 /* Uil will automatically strip this prefix when saving name of automatically
105  * created child.  This is used to prevent name conflicts in existing uil
106  * files.  Children names without this prefix will be saved as is.
107  */
108 #define AUTO_CHILD_PREFIX "Xm_"
109 
110 /*
111 **
112 **  Constants controlling limits in the compiler
113 **
114 */
115 
116 #define src_k_max_source_files		101
117 #define src_k_max_source_line_length	132
118 #define lex_k_unprint_sub		'?'
119 #define sym_k_max_list_count		1000
120 #define sym_k_max_color_count		256
121 #define Uil_k_max_include_dir_count	32
122 
123 /*
124 **
125 **  Definition of Compiler Termination Statuses
126 **
127 */
128 
129 #define uil_k_min_status	Uil_k_min_status
130 #define uil_k_success_status	Uil_k_success_status
131 #define uil_k_info_status	Uil_k_info_status
132 #define uil_k_warning_status	Uil_k_warning_status
133 #define uil_k_error_status	Uil_k_error_status
134 #define uil_k_severe_status	Uil_k_severe_status
135 #define uil_k_max_status	Uil_k_max_status
136 
137 
138 /*
139 **
140 **  Macros to access bit vectors
141 **
142 */
143 
144 /* MOVED TO DBDef.h */
145 
146 
147 /*
148 **
149 **  Upper and Lower Case Translation Macros
150 **
151 */
152 
153 #define _upper(c)	((c) >= 'a' && (c) <= 'z' ? (c) & 0x5F:(c))
154 #define _lower(c)	((c) >= 'A' && (c) <= 'Z' ? (c) | 0x20:(c))
155 
156 
157 /*
158 **
159 **  Assert Macro
160 **
161 */
162 
163 #if debug_version
164 #define _assert( __condition, __text )			\
165 	if (!(__condition))				\
166 	{  diag_issue_internal_error( (__text)); }
167 #else
168 #define _assert( __condition, __text )			\
169 	if (!(__condition))				\
170 	{  diag_issue_internal_error( NULL ); }
171 #endif
172 
173 /*
174 **
175 **  _error and _okay macro
176 **
177 */
178 
179 #define _error( __status )	\
180 	((__status & 1)==0)
181 
182 #define _success( __status )	\
183 	((__status & 1)==1)
184 
185 
186 /*
187 **
188 **  Memory allocation definitions
189 **
190 */
191 
192 #define _get_memory XtMalloc
193 
194 #define _free_memory XtFree
195 
196 /*
197 **
198 **  Move macro
199 **
200 */
201 
202 #ifdef NO_MEMMOVE
203 /* For fixing the bug CR 4581 */
204 extern char* uil_mmove(char*, char*, int);
205 
206 #define _move uil_mmove
207 #else
208 #define _move memmove
209 #endif /* NO_MEMMOVE */
210 
211 /*
212 **
213 **  Compare macro
214 **
215 */
216 
217 #define _compare strcmp
218 
219 /*
220 **
221 **  Fill macro
222 **
223 */
224 
225 #define _fill( __string, __char, __len )	\
226     {						\
227       register int i = __len; 			\
228       while (--i >= 0)				\
229 	(__string)[i] = __char;			\
230     }
231 
232 /*
233 **
234 **  Index macro
235 **
236 */
237 
238 #define _index( __char, __string, __len ) \
239     ((int)((char *)memchr( __string, __char, __len ) - (char *)__string ))
240 
241 /*
242 **
243 **  Debug output macro
244 **
245 */
246 #if debug_version
247 #define _debug_output lst_debug_output
248 #else
249 #define _debug_output printf
250 #endif
251 
252 
253 /*
254 **
255 ** Common includes needed by most modules
256 **
257 */
258 #include "Uil.h"
259 #include "UilDBDef.h"                      /* for binary database */
260 #include "UilMess.h"
261 #include "UilSymDef.h"			/* must come before UilKeyDef.h */
262 #include "UilSrcDef.h"			/* must come before UilIODef.h */
263 #include "UilIODef.h"
264 #include "UilDiagDef.h"
265 #include "UilSarDef.h"
266 #if defined(linux) || defined(__APPLE__) || defined(__FreeBSD__) \
267  || defined(__DragonFly__)
268 #define YYSTYPE yystype
269 #endif
270 #include "UilLexPars.h"
271 #include "UilCmdDef.h"
272 #include "UilLexDef.h"
273 
274 /*
275 ** Global declarations
276 */
277 #include "UilSymGl.h"
278 #include "UilCompGl.h"
279 
280 /* Needed for following macro. */
281 #include "UilSymGen.h"
282 
283 #define DEFAULT_TAG uil_charset_names[sym_k_XmFONTLIST_DEFAULT_TAG_charset]
284 
285 /*
286 ** Function declarations not defined elsewhere
287 */
288 #define _ARGUMENTS(arglist) arglist
289 
290 /* uilcmd.c */
291 
292 #if defined(__cplusplus) || defined(c_plusplus)
293 extern "C" {
294 #endif
295 
296 extern void diag_issue_diagnostic
297 	_ARGUMENTS(( int d_message_number ,
298 		    src_source_record_type *az_src_rec ,
299 		    int l_start_column, ... ));
300 extern void lst_debug_output  _ARGUMENTS(( char *format, ... ));
301 
302 
303 void cmd_decode_command_line  _ARGUMENTS(( int l_arg_count , char *rac_arg_value []));
304 
305 /* uildb.c */
306 extern void db_incorporate _ARGUMENTS(( void ));
307 extern void db_read_ints_and_string _ARGUMENTS((_db_header_ptr header));
308 extern void db_read_char_table _ARGUMENTS((_db_header_ptr header));
309 extern void db_read_length_and_string _ARGUMENTS((_db_header_ptr header));
310 extern void db_read_int_and_shorts _ARGUMENTS((_db_header_ptr header));
311 extern void db_open_file _ARGUMENTS(( void ));
312 extern String get_root_dir_name _ARGUMENTS(( void ));
313 extern String init_wmd_path _ARGUMENTS((String filename));
314 
315 /* uildiags.c */
316 extern void diag_issue_summary  _ARGUMENTS(( void ));
317 extern char *diag_tag_text  _ARGUMENTS(( int XmConst b_tag ));
318 extern char *diag_object_text  _ARGUMENTS(( int XmConst b_type ));
319 extern char *diag_value_text  _ARGUMENTS(( int XmConst b_type ));
320 extern char *diag_charset_text  _ARGUMENTS(( int XmConst b_type ));
321 extern void diag_initialize_diagnostics  _ARGUMENTS(( void ));
322 extern void diag_restore_diagnostics  _ARGUMENTS(( void ));
323 extern void diag_reset_overflow_handler  _ARGUMENTS(( void ));
324 extern void diag_handler  _ARGUMENTS(( int l_error ));
325 extern void diag_issue_internal_error  _ARGUMENTS(( char *error_text ));
326 extern void write_msg_to_standard_error  _ARGUMENTS(( XmConst int message_number , XmConst char *src_buffer , XmConst char *ptr_buffer , XmConst char *msg_buffer , XmConst char *loc_buffer ));
327 extern char XmConst *diag_get_message_abbrev  _ARGUMENTS(( int d_message_number ));
328 extern void diag_report_status  _ARGUMENTS(( void ));
329 
330 /* uilkeytab.c */
331 extern key_keytable_entry_type *key_find_keyword  _ARGUMENTS(( unsigned int symbol_length , char *symbol_ptr ));
332 extern void key_initialize  _ARGUMENTS(( void ));
333 
334 /* uillexana.c */
335 extern int yylex  _ARGUMENTS(( void ));
336 extern void lex_initialize_analyzer  _ARGUMENTS(( void ));
337 extern void Uil_lex_cleanup_analyzer  _ARGUMENTS(( void ));
338 extern void lex_issue_error  _ARGUMENTS(( int restart_token ));
339 extern void issue_control_char_diagnostic  _ARGUMENTS(( unsigned char c_char ));
340 extern void lex_filter_unprintable_chars  _ARGUMENTS(( unsigned char *buffer , int length , unsigned long flags ));
341 extern long cvt_ascii_to_long  _ARGUMENTS(( unsigned char XmConst *c_text ));
342 extern sym_value_entry_type *create_str_entry  _ARGUMENTS(( int l_size , int l_charset , sym_value_entry_type *az_charset_entry ));
343 
344 /* uillstlst.c */
345 extern void lst_open_listing  _ARGUMENTS(( void ));
346 extern void Uil_lst_cleanup_listing  _ARGUMENTS(( void ));
347 extern status create_listing_file  _ARGUMENTS(( uil_fcb_type *az_fcb ));
348 extern void lst_output_line  _ARGUMENTS(( char *ac_line , boolean v_new_page ));
349 extern char *current_time  _ARGUMENTS(( _Xctimeparams *ctime_buf ));
350 extern void lst_output_listing  _ARGUMENTS(( void ));
351 extern void lst_output_messages  _ARGUMENTS(( src_message_item_type *az_message_item ));
352 extern void lst_output_machine_code  _ARGUMENTS(( src_source_record_type *az_src_rec ));
353 extern void lst_output_message_ptr_line  _ARGUMENTS(( src_source_record_type *az_src_rec , char *src_buffer ));
354 
355 /* uillstmac.c */
356 extern void save_widget_machine_code  _ARGUMENTS(( sym_widget_entry_type *widget_entry , URMResourceContext *az_context ));
357 extern void unload_stack  _ARGUMENTS(( char *rec , int rec_size , src_source_record_type *az_src_rec ));
358 extern void save_value_machine_code  _ARGUMENTS(( sym_value_entry_type *value_entry , URMResourceContext *az_context ));
359 extern void save_module_machine_code  _ARGUMENTS(( src_source_record_type *az_src_rec , URMResourceContext *az_context ));
360 extern void off_put  _ARGUMENTS(( unsigned short off_type , unsigned short off_offset ));
361 extern void off_get  _ARGUMENTS(( unsigned short *off_type , unsigned short *off_offset ));
362 extern char *type_from_code  _ARGUMENTS(( MrmType type_code ));
363 extern char *access_from_code  _ARGUMENTS(( MrmFlag access_code ));
364 extern char *group_from_code  _ARGUMENTS(( MrmGroup group_code ));
365 extern void format_arg_value  _ARGUMENTS(( RGMArgValuePtr argval_ptr , char *buffer ));
366 extern char *class_name_from_code  _ARGUMENTS(( MrmCode mrm_class ));
367 extern char *resource_name_from_code  _ARGUMENTS(( MrmCode resource ));
368 
369 /* uilmain.c */
370 extern void uil_exit  _ARGUMENTS(( int severity ));
371 extern Uil_status_type Uil _ARGUMENTS((Uil_command_type
372 *comand_desc,Uil_compile_desc_type *compile_desc,Uil_continue_type
373 (*message_cb)(), char *message_data, Uil_continue_type (*status_cb)(),
374 char *status_data));
375 
376 
377 /* uilp2out.c */
378 extern void sem_output_uid_file  _ARGUMENTS(( void ));
379 extern void push  _ARGUMENTS(( sym_entry_type *sym_entry ));
380 extern sym_entry_type *pop  _ARGUMENTS(( void ));
381 extern void out_emit_widget  _ARGUMENTS(( sym_widget_entry_type *widget_entry ));
382 extern void extract_subtree_control  _ARGUMENTS(( sym_list_entry_type *list_entry , sym_control_entry_type **menu_entry , int *count ));
383 extern void extract_create_callback  _ARGUMENTS(( sym_list_entry_type *list_entry , sym_callback_entry_type **create_entry ));
384 extern void process_all_callbacks  _ARGUMENTS(( sym_list_entry_type *list_entry , int *arglist_index ));
385 extern void process_all_arguments  _ARGUMENTS(( sym_list_entry_type *list_entry , int *arglist_index , int *related_count ));
386 extern void process_all_controls  _ARGUMENTS(( sym_list_entry_type *list_entry , int *widget_index ));
387 extern void out_emit_value  _ARGUMENTS(( sym_value_entry_type *value_entry ));
388 extern void emit_callback  _ARGUMENTS(( sym_callback_entry_type *callback_entry , int *arglist_index , boolean emit_create ));
389 extern void emit_callback_procedures _ARGUMENTS(( sym_proc_ref_entry_type *proc_ref_entry_next, int *proc_ref_index, MrmOffset callback_offset ));
390 extern int count_proc _ARGUMENTS(( sym_list_entry_type *proc_list, int count));
391 extern void emit_argument  _ARGUMENTS(( sym_argument_entry_type *argument_entry , int arglist_index , int *related_arg_count ));
392 extern void emit_control  _ARGUMENTS(( sym_control_entry_type *control_entry , int control_offset ));
393 extern MrmCode ref_value  _ARGUMENTS(( sym_value_entry_type *value_entry , MrmCode *arg_type , long *arg_value , MrmCode *arg_access , char **arg_index , MrmResource_id *arg_id , MrmCode *arg_group ));
394 extern MrmCode ref_control  _ARGUMENTS(( sym_control_entry_type *control_entry , MrmCode *access , char **index , MrmResource_id *id ));
395 extern void issue_urm_error  _ARGUMENTS(( char *problem ));
396 extern MrmCode Urm_code_from_uil_type  _ARGUMENTS(( int uil_type ));
397 extern int compute_color_table_size  _ARGUMENTS(( sym_value_entry_type *table_entry ));
398 extern void create_color_table  _ARGUMENTS(( sym_value_entry_type *table_entry , char *buffer ));
399 extern int compute_icon_size  _ARGUMENTS(( sym_value_entry_type *icon_entry ));
400 extern void create_icon  _ARGUMENTS(( sym_value_entry_type *icon_entry , char *buffer ));
401 extern int compute_list_size  _ARGUMENTS(( sym_list_entry_type *list_entry , int type ));
402 extern void create_int_compression_codes  _ARGUMENTS(( void ));
403 extern void create_ext_compression_codes  _ARGUMENTS(( void ));
404 
405 /* uilp2reslv.c */
406 extern void sem_resolve_forward_refs  _ARGUMENTS(( void ));
407 
408 /* uilsarcomp.c */
409 extern sym_value_entry_type *sem_create_cstr  _ARGUMENTS(( void ));
410 extern sym_value_entry_type *sem_create_wchar_str  _ARGUMENTS(( void ));
411 extern void sem_append_str_to_cstr  _ARGUMENTS(( sym_value_entry_type *az_cstr_entry , sym_value_entry_type *az_str_entry , boolean op2_temporary ));
412 extern void sem_append_cstr_to_cstr  _ARGUMENTS(( sym_value_entry_type *az_cstr1_entry , sym_value_entry_type *az_cstr2_entry , boolean op2_temporary ));
413 extern sym_value_entry_type *sem_cat_str_to_str  _ARGUMENTS(( sym_value_entry_type *az_str1_entry , boolean op1_temporary , sym_value_entry_type *az_str2_entry , boolean op2_temporary ));
414 extern int sem_map_subclass_to_charset  _ARGUMENTS(( int charset_as_subclass ));
415 extern void sar_charset_verify  _ARGUMENTS(( yystype *charset_frame ));
416 extern void sar_make_fallback_charset _ARGUMENTS((yystype *name_frame));
417 extern void sar_chk_charset_attr  _ARGUMENTS(( yystype *target_frame , yystype *value_frame , yystype *prior_value_frame ));
418 extern void sar_make_charset  _ARGUMENTS(( yystype *target_frame , yystype *value_frame , yystype *attr_frame , yystype *keyword_frame ));
419 
420 /* uilsarexp.c */
421 extern void sar_binary_op  _ARGUMENTS(( yystype *operator_frame , yystype *op1_frame , yystype *op2_frame ));
422 extern void sar_unary_op  _ARGUMENTS(( yystype *operator_frame , yystype *op1_frame ));
423 
424 /* uilsarinc.c */
425 extern void sar_include_file  _ARGUMENTS(( yystype *file_frame , yystype *include_frame , yystype *semi_frame ));
426 
427 /* uilsarmod.c */
428 extern void sar_initialize  _ARGUMENTS(( void ));
429 extern void sar_create_root  _ARGUMENTS(( yystype *root_frame ));
430 extern void sar_create_module  _ARGUMENTS(( yystype *target_frame , yystype *id_frame , yystype *module_frame ));
431 extern void sar_process_module_version  _ARGUMENTS(( yystype *value_frame , yystype *start_frame ));
432 extern void sar_process_module_sensitivity  _ARGUMENTS(( yystype *token_frame , yystype *start_frame ));
433 extern void sar_process_module_charset  _ARGUMENTS(( yystype *token_frame , yystype *start_frame ));
434 extern void sar_save_module_source  _ARGUMENTS(( void ));
435 extern void sar_make_def_obj  _ARGUMENTS(( yystype *object_frame ));
436 extern void sar_process_module_variant  _ARGUMENTS(( yystype *obj_type_frame , yystype *variant_frame ));
437 extern void sar_save_section_source  _ARGUMENTS(( yystype *header_frame , int section_type ));
438 
439 /* uilsarobj.c */
440 extern void sar_assoc_comment  _ARGUMENTS(( sym_obj_entry_type    *object ));
441 extern void sar_create_object  _ARGUMENTS(( yystype *object_frame , unsigned char object_type ));
442 extern void sar_create_child  _ARGUMENTS(( yystype *object_frame ));
443 extern void sar_link_section  _ARGUMENTS(( yystype *id_frame ));
444 extern void sar_save_src_semicolon_pos  _ARGUMENTS(( yystype *semi_frame ));
445 extern void sar_save_list_end  _ARGUMENTS(( yystype *close_frame ));
446 extern void sar_save_src_entry_end  _ARGUMENTS(( yystype *close_frame , yystype *entry_frame ));
447 extern void sar_set_object_flags  _ARGUMENTS(( yystype *current_frame , unsigned char mask ));
448 extern void sar_unset_object_flags  _ARGUMENTS(( yystype *current_frame , unsigned char mask ));
449 extern void sar_set_list_type  _ARGUMENTS(( yystype *current_frame ));
450 extern void sar_set_object_class  _ARGUMENTS(( yystype *current_frame ));
451 extern void sar_set_object_variant  _ARGUMENTS(( yystype *current_frame ));
452 extern yystype *sem_find_object  _ARGUMENTS(( yystype *current_frame ));
453 extern void sar_object_reference  _ARGUMENTS(( yystype *ref_frame ));
454 extern void sar_update_parent_list  _ARGUMENTS(( yystype *control_list_frame ));
455 extern void parent_list_traverse  _ARGUMENTS(( sym_widget_entry_type *widget_entry , sym_list_entry_type *control_list_entry ));
456 extern void sar_save_feature  _ARGUMENTS(( yystype *feature_frame ));
457 extern void sar_save_argument_pair  _ARGUMENTS(( yystype *argument_frame , yystype *value_frame , yystype *equals_frame ));
458 extern void sar_save_reason_binding  _ARGUMENTS(( yystype *reason_frame , yystype *proc_ref_frame , yystype *equals_frame ));
459 extern void sar_save_control_item  _ARGUMENTS(( yystype *managed_frame , yystype *item_frame ));
460 extern void sar_save_control_widget  _ARGUMENTS(( yystype *control_frame , yystype *item_frame ));
461 extern void sar_save_user_proc_ref_src  _ARGUMENTS(( yystype *procedure_frame , yystype *proc_id_frame , yystype *proc_arg_frame ));
462 extern void sar_process_proc_ref  _ARGUMENTS(( yystype *proc_id_frame , yystype *proc_arg_frame , int context ));
463 extern void sar_add_list_entry  _ARGUMENTS(( yystype *entry_frame ));
464 extern void sar_add_forward_list_entry  _ARGUMENTS(( yystype *entry_frame ));
465 extern void sar_verify_object  _ARGUMENTS(( yystype *current_frame ));
466 extern sym_entry_type *sem_allocate_node  _ARGUMENTS(( unsigned char node_tag , unsigned short node_size ));
467 extern void sem_free_node  _ARGUMENTS(( sym_entry_type *node_ptr ));
468 
469 /* uilsarproc.c */
470 extern void sar_create_procedure  _ARGUMENTS(( XmConst yystype *id_frame , XmConst yystype *param_frame , XmConst yystype *class_frame , XmConst yystype *semi_frame ));
471 extern sym_proc_ref_entry_type *sem_reference_procedure  _ARGUMENTS(( yystype *id_frame , XmConst yystype *value_frame , XmConst int context ));
472 extern sym_entry_type *sem_ref_name  _ARGUMENTS(( yystype *id_frame , XmConst int tag ));
473 
474 /* uilsarval.c */
475 extern void sar_map_keyword_to_name  _ARGUMENTS(( yystype *target_frame , yystype *keyword_frame ));
476 extern void sar_process_id  _ARGUMENTS(( yystype *target_frame , yystype *id_frame ));
477 extern void sar_process_id_ref  _ARGUMENTS(( yystype *id_frame ));
478 extern void sar_make_private_value  _ARGUMENTS(( yystype *value_frame , yystype *token_frame , int value_type , yystype *keyword_frame , int arg_type ));
479 extern void sar_make_rgb_private_value  _ARGUMENTS(( yystype *value_frame , yystype *token_frame , int value_type , yystype *keyword_frame , int arg_type ));
480 extern void sar_append_table_value  _ARGUMENTS(( yystype *value_frame , yystype *table_frame , int table_type , yystype *comma_frame ));
481 extern void sar_value_not_implemented  _ARGUMENTS(( yystype *value_frame , yystype *token_frame , char *error_text ));
482 extern void sar_cat_value  _ARGUMENTS(( yystype *operator_frame , yystype *op1_frame , yystype *op2_frame ));
483 extern void sar_chk_comp_str_attr  _ARGUMENTS(( yystype *target_frame , yystype *value_frame , yystype *prior_value_frame ));
484 extern void sar_make_comp_str  _ARGUMENTS(( yystype *target_frame , yystype *value_frame , yystype *attr_frame , yystype *keyword_frame ));
485 extern void sar_make_comp_str_comp _ARGUMENTS((yystype *target_frame, yystype *type_frame, yystype *value_frame, yystype *keyword_frame));
486 extern void sar_make_wchar_str  _ARGUMENTS(( yystype *target_frame , yystype *value_frame , yystype *attr_frame , yystype *keyword_frame ));
487 extern void sar_value_type_error  _ARGUMENTS(( yystype *value_frame , int expected_type ));
488 extern void sar_private_error  _ARGUMENTS(( yystype *value_frame ));
489 extern void sar_import_value_entry  _ARGUMENTS(( yystype *target_frame , yystype *token_frame ));
490 extern void sar_bind_value_name  _ARGUMENTS(( yystype *id_frame , yystype *value_frame , yystype *semi_frame ));
491 extern sym_name_entry_type *sem_dcl_name  _ARGUMENTS(( XmConst yystype *id_frame ));
492 extern sym_value_entry_type *sem_create_value_entry  _ARGUMENTS(( char *value , int length , int value_type ));
493 extern void sar_create_identifier  _ARGUMENTS(( XmConst yystype *id_frame , XmConst yystype *semi_frame ));
494 extern void sar_make_font_table  _ARGUMENTS(( yystype *target_frame , yystype *font_frame , yystype *prior_target_frame , yystype *keyword_frame ));
495 extern void sar_make_font_item  _ARGUMENTS(( yystype *target_frame , yystype *charset_frame , yystype *font_frame ));
496 extern void sar_make_font  _ARGUMENTS(( yystype *target_frame , yystype *charset_frame , yystype *value_frame , yystype *keyword_frame ));
497 extern void sar_make_fontset  _ARGUMENTS(( yystype *target_frame , yystype *charset_frame , yystype *value_frame , yystype *keyword_frame ));
498 extern void sar_make_color_item  _ARGUMENTS(( yystype *target_frame , yystype *color_frame , yystype *letter_frame ));
499 extern void sar_append_color_item  _ARGUMENTS(( yystype *target_frame , yystype *item_frame , yystype *prior_target_frame ));
500 extern void sar_make_color_table  _ARGUMENTS(( yystype *target_frame , yystype *list_frame , yystype *keyword_frame ));
501 extern void sar_make_color  _ARGUMENTS(( yystype *target_frame , yystype *color_frame , yystype *mono_frame , yystype *keyword_frame ));
502 extern void sar_make_icon  _ARGUMENTS(( yystype *target_frame , yystype *list_frame , yystype *table_frame , yystype *keyword_frame ));
503 
504 /* uilsemcset.c */
505 extern char *sem_charset_name  _ARGUMENTS(( int l_charset , sym_value_entry_type *az_charset_entry ));
506 extern void sem_charset_info  _ARGUMENTS(( int l_charset , sym_value_entry_type *az_charset_entry , int *write_direction , int *parse_direction , int *sixteen_bit ));
507 extern int sem_charset_lang_name  _ARGUMENTS(( char *lang_charset ));
508 
509 /* uilsemval.c */
510 typedef	union  	{
511 	    boolean	boolean_value;
512 	    int		integer_value;
513 	    double	real_value;
514 	    char        character_value;   /* character data type RAP */
515 	    float       single_float_value; /* single float data type RAP */
516 	} data_value_type;
517 
518 extern void sem_validation  _ARGUMENTS(( void ));
519 extern void sem_validate_node  _ARGUMENTS(( sym_entry_type *node ));
520 extern sym_value_entry_type *sem_validate_value_node  _ARGUMENTS(( sym_value_entry_type *value_node ));
521 extern void sem_validate_widget_node  _ARGUMENTS(( sym_widget_entry_type *widget_node ));
522 extern void sem_validate_argument_list  _ARGUMENTS(( sym_widget_entry_type *widget_node , unsigned int widget_type , sym_list_entry_type *list_entry , sym_argument_entry_type **seen ));
523 extern void sem_validate_argument_entry  _ARGUMENTS(( sym_widget_entry_type *widget_node , unsigned int widget_type , sym_list_entry_type *list_entry , sym_argument_entry_type *argument_entry , sym_argument_entry_type **seen ));
524 extern void sem_validate_argument_enumset  _ARGUMENTS(( sym_argument_entry_type *argument_entry , int arg_code , sym_value_entry_type *arg_value_entry ));
525 extern void sem_validate_constraint_entry  _ARGUMENTS(( sym_widget_entry_type *widget_node , sym_argument_entry_type *argument_entry, unsigned int widget_type ));
526 extern void sem_validate_callback_list  _ARGUMENTS(( sym_widget_entry_type *widget_node , unsigned int widget_type , sym_list_entry_type *list_entry , sym_callback_entry_type **seen ));
527 extern void sem_validate_callback_entry  _ARGUMENTS(( sym_widget_entry_type *widget_node , unsigned int widget_type , sym_list_entry_type *list_entry , sym_callback_entry_type *callback_entry , sym_callback_entry_type **seen ));
528 extern void sem_validate_control_list  _ARGUMENTS(( sym_widget_entry_type *widget_node , unsigned int widget_type , sym_list_entry_type *list_entry , int *count ));
529 extern void sem_validate_control_entry  _ARGUMENTS(( sym_widget_entry_type *widget_node , unsigned int widget_type , sym_list_entry_type *list_entry , sym_control_entry_type *control_entry , int *gadget_count ));
530 extern void sem_validate_widget_cycle  _ARGUMENTS(( sym_list_entry_type *list_entry , sym_name_entry_type *cycle_name ));
531 extern boolean sem_validate_widget_cycle_aux  _ARGUMENTS(( sym_list_entry_type *list_entry , sym_name_entry_type *cycle_name ));
532 extern boolean sem_validate_verify_cycle  _ARGUMENTS(( sym_widget_entry_type *cycle_obj , sym_list_entry_type *list_entry ));
533 extern void sem_validate_procref_list  _ARGUMENTS(( sym_list_entry_type *list_entry ));
534 extern void sem_validate_procref_entry  _ARGUMENTS(( sym_proc_ref_entry_type *procref_entry ));
535 extern boolean sem_argument_allowed  _ARGUMENTS(( unsigned int arg_code , unsigned int class_code ));
536 extern boolean sem_reason_allowed  _ARGUMENTS(( unsigned int rsn_code , unsigned int class_code ));
537 extern boolean sem_control_allowed  _ARGUMENTS(( unsigned int ctl_code , unsigned int class_code ));
538 extern boolean sem_child_allowed  _ARGUMENTS(( unsigned int ctl_code , unsigned int class_code ));
539 extern sym_value_entry_type *sem_evaluate_value  _ARGUMENTS(( sym_value_entry_type *val_entry ));
540 extern sym_value_entry_type *sem_evaluate_value_cs  _ARGUMENTS(( sym_value_entry_type *csval_entry ));
541 /* BEGIN OSF Fix CR 4859 */
542 /* END OSF Fix CR 4859 */
543 extern sym_value_entry_type *sem_evaluate_value_expr  _ARGUMENTS(( sym_value_entry_type *value_entry ));
544 extern int validate_arg  _ARGUMENTS(( sym_value_entry_type *operand_entry , int v_operator ));
545 extern int sem_convert_to_float  _ARGUMENTS(( sym_value_entry_type *operand_entry , data_value_type *data_value ));
546 extern int sem_convert_to_integer  _ARGUMENTS(( sym_value_entry_type *operand_entry , data_value_type *data_value ));
547 extern int sem_convert_to_single_float  _ARGUMENTS(( sym_value_entry_type *operand_entry , data_value_type *data_value ));
548 extern int sem_convert_to_error  _ARGUMENTS(( sym_value_entry_type *operand_entry , data_value_type *data_value ));
549 extern void sar_cat_value_entry  _ARGUMENTS(( sym_value_entry_type **target_entry , sym_value_entry_type *op1_entry , sym_value_entry_type *op2_entry ));
550 
551 /* uilsrcsrc.c */
552 extern void src_initialize_source  _ARGUMENTS(( void ));
553 extern void Uil_src_cleanup_source  _ARGUMENTS(( void ));
554 extern void src_open_file  _ARGUMENTS(( XmConst char *c_file_name , char *full_file_name ));
555 extern status src_get_source_line  _ARGUMENTS(( void ));
556 extern status open_source_file  _ARGUMENTS(( XmConst char *c_file_name , uil_fcb_type *az_fcb , src_source_buffer_type *az_source_buffer ));
557 extern status close_source_file  _ARGUMENTS(( uil_fcb_type *az_fcb ));
558 extern status get_line  _ARGUMENTS(( uil_fcb_type *az_fcb ));
559 extern boolean reget_line  _ARGUMENTS(( uil_fcb_type *az_fcb , char *c_buffer , XmConst z_key *z_access_key ));
560 extern char *src_get_file_name  _ARGUMENTS(( XmConst src_source_record_type *az_src_rec ));
561 extern boolean src_retrieve_source  _ARGUMENTS(( XmConst src_source_record_type *az_src_rec , char *c_buffer ));
562 extern void src_append_diag_info  _ARGUMENTS(( XmConst src_source_record_type *az_src_rec , XmConst int l_src_pos , XmConst char *c_msg_text , XmConst int l_msg_number ));
563 extern void src_append_machine_code  _ARGUMENTS(( src_source_record_type *az_src_rec , XmConst int l_offset , XmConst int l_code_len , XmConst char *c_code , XmConst char *c_text_arg ));
564 
565 /* uilsymnam.c */
566 extern sym_name_entry_type *sym_find_name  _ARGUMENTS(( int l_length , char *c_text ));
567 extern sym_name_entry_type *sym_insert_name  _ARGUMENTS(( int l_length , char *c_text ));
568 extern int hash_function  _ARGUMENTS(( int l_length , char *c_value ));
569 #if debug_version
570 extern void sym_dump_hash_table  _ARGUMENTS(( void ));
571 #endif
572 
573 /* uilsymstor.c */
574 extern void sym_initialize_storage  _ARGUMENTS(( void ));
575 extern void Uil_sym_cleanup_storage  _ARGUMENTS(( boolean freealloc ));
576 extern void sym_make_external_def  _ARGUMENTS(( XmConst sym_name_entry_type *az_name ));
577 extern void sym_make_forward_ref  _ARGUMENTS(( XmConst yystype *az_id_frame , XmConst int l_widget_type , XmConst char *a_location ));
578 extern void sym_make_value_forward_ref  _ARGUMENTS(( XmConst yystype *az_value_frame , XmConst char *a_location , XmConst unsigned char fwd_ref_flags ));
579 extern void UilDumpSymbolTable  _ARGUMENTS(( sym_entry_type *node_entry ));
580 extern void sym_dump_symbols  _ARGUMENTS(( void ));
581 extern void sym_dump_symbol  _ARGUMENTS(( sym_entry_type *az_symbol_entry ));
582 extern void sym_dump_widget  _ARGUMENTS(( XmConst sym_widget_entry_type *az_widget_entry ));
583 extern void sym_dump_argument  _ARGUMENTS(( XmConst sym_argument_entry_type *az_argument_entry ));
584 extern void sym_dump_control  _ARGUMENTS(( XmConst sym_control_entry_type *az_control_entry ));
585 extern void sym_dump_callback  _ARGUMENTS(( XmConst sym_callback_entry_type *az_callback_entry ));
586 extern void sym_dump_list  _ARGUMENTS(( XmConst sym_list_entry_type *az_list_entry ));
587 extern void sym_dump_name  _ARGUMENTS(( XmConst sym_name_entry_type *az_name_entry ));
588 extern void sym_dump_module  _ARGUMENTS(( XmConst sym_module_entry_type *az_module_entry ));
589 extern void sym_dump_color_item  _ARGUMENTS(( XmConst sym_color_item_entry_type *az_color_item_entry ));
590 extern void sym_dump_parent_list_item  _ARGUMENTS(( XmConst sym_parent_list_type *az_parent_list_item ));
591 extern void sym_dump_external_def  _ARGUMENTS(( XmConst sym_external_def_entry_type *az_external_def_entry ));
592 extern void sym_dump_proc_def  _ARGUMENTS(( XmConst sym_proc_def_entry_type *az_proc_def_entry ));
593 extern void sym_dump_proc_ref  _ARGUMENTS(( XmConst sym_proc_ref_entry_type *az_proc_ref_entry ));
594 extern void sym_dump_forward_ref  _ARGUMENTS(( XmConst sym_forward_ref_entry_type *az_forward_ref_entry ));
595 extern void sym_dump_value  _ARGUMENTS(( XmConst sym_value_entry_type *az_value_entry ));
596 extern void output_text  _ARGUMENTS(( XmConst int length , XmConst char *text ));
597 extern void sym_dump_source_info  _ARGUMENTS(( sym_entry_header_type *hdr ));
598 extern void sym_dump_obj_header  _ARGUMENTS(( XmConst sym_obj_entry_type *az_obj_entry ));
599 extern void sym_dump_include_file  _ARGUMENTS(( sym_include_file_entry_type *az_symbol_entry ));
600 extern void sym_dump_section  _ARGUMENTS(( sym_section_entry_type *az_symbol_entry ));
601 extern void sym_dump_object_variant  _ARGUMENTS(( sym_def_obj_entry_type *az_symbol_entry ));
602 extern void sym_dump_root_entry  _ARGUMENTS(( sym_root_entry_type *az_symbol_entry ));
603 extern char *sym_section_text  _ARGUMENTS(( int b_type ));
604 extern void dump_free_list  _ARGUMENTS(( void ));
605 extern int sar_get_units_type (yystype *parse_frame);
606 #if defined(__cplusplus) || defined(c_plusplus)
607 }
608 #endif
609 
610 #endif /* UilDefI_h */
611 /* DON'T ADD STUFF AFTER THIS #endif */
612