Subversion Repositories tendra.SVN

Rev

Rev 5 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5 Rev 6
Line 40... Line 40...
40
#include "cmd_ops.h"
40
#include "cmd_ops.h"
41
 
41
 
42
/* Printing function declarations */
42
/* Printing function declarations */
43
 
43
 
44
#ifndef PRINT_list_cmd
44
#ifndef PRINT_list_cmd
45
static void PRINT_list_cmd PROTO_S ( ( FILE *, LIST ( COMMAND ), char *, int ) ) ;
45
static void PRINT_list_cmd (FILE *, LIST(COMMAND), char *, int);
46
#endif
46
#endif
47
 
47
 
48
#ifndef PRINT_cmd
48
#ifndef PRINT_cmd
49
static void PRINT_cmd PROTO_S ( ( FILE *, COMMAND, char *, int ) ) ;
49
static void PRINT_cmd (FILE *, COMMAND, char *, int);
50
#endif
50
#endif
51
 
51
 
52
#ifndef PRINT_list_ptr_map
52
#ifndef PRINT_list_ptr_map
53
static void PRINT_list_ptr_map PROTO_S ( ( FILE *, LIST ( PTR ( MAP ) ), char *, int ) ) ;
53
static void PRINT_list_ptr_map (FILE *, LIST(PTR(MAP)), char *, int);
54
#endif
54
#endif
55
 
55
 
56
#ifndef PRINT_list_MAP_P
56
#ifndef PRINT_list_MAP_P
57
#define PRINT_list_MAP_P( A, B, C, D ) PRINT_list_ptr_map ( ( A ), ( B ), ( C ), ( D ) )
57
#define PRINT_list_MAP_P(A, B, C, D)PRINT_list_ptr_map((A), (B), (C), (D))
58
#endif
58
#endif
59
 
59
 
60
#ifndef PRINT_list_ptr_fld
60
#ifndef PRINT_list_ptr_fld
61
static void PRINT_list_ptr_fld PROTO_S ( ( FILE *, LIST ( PTR ( FIELD ) ), char *, int ) ) ;
61
static void PRINT_list_ptr_fld (FILE *, LIST(PTR(FIELD)), char *, int);
62
#endif
62
#endif
63
 
63
 
64
#ifndef PRINT_list_FIELD_P
64
#ifndef PRINT_list_FIELD_P
65
#define PRINT_list_FIELD_P( A, B, C, D ) PRINT_list_ptr_fld ( ( A ), ( B ), ( C ), ( D ) )
65
#define PRINT_list_FIELD_P(A, B, C, D)PRINT_list_ptr_fld((A), (B), (C), (D))
66
#endif
66
#endif
67
 
67
 
68
#ifndef PRINT_list_ptr_arg
68
#ifndef PRINT_list_ptr_arg
69
static void PRINT_list_ptr_arg PROTO_S ( ( FILE *, LIST ( PTR ( ARGUMENT ) ), char *, int ) ) ;
69
static void PRINT_list_ptr_arg (FILE *, LIST(PTR(ARGUMENT)), char *, int);
70
#endif
70
#endif
71
 
71
 
72
#ifndef PRINT_list_ARGUMENT_P
72
#ifndef PRINT_list_ARGUMENT_P
73
#define PRINT_list_ARGUMENT_P( A, B, C, D ) PRINT_list_ptr_arg ( ( A ), ( B ), ( C ), ( D ) )
73
#define PRINT_list_ARGUMENT_P(A, B, C, D)PRINT_list_ptr_arg((A), (B), (C), (D))
74
#endif
74
#endif
75
 
75
 
76
#ifndef PRINT_list_ptr_cmp
76
#ifndef PRINT_list_ptr_cmp
77
static void PRINT_list_ptr_cmp PROTO_S ( ( FILE *, LIST ( PTR ( COMPONENT ) ), char *, int ) ) ;
77
static void PRINT_list_ptr_cmp (FILE *, LIST(PTR(COMPONENT)), char *, int);
78
#endif
78
#endif
79
 
79
 
80
#ifndef PRINT_list_COMPONENT_P
80
#ifndef PRINT_list_COMPONENT_P
81
#define PRINT_list_COMPONENT_P( A, B, C, D ) PRINT_list_ptr_cmp ( ( A ), ( B ), ( C ), ( D ) )
81
#define PRINT_list_COMPONENT_P(A, B, C, D)PRINT_list_ptr_cmp((A), (B), (C), (D))
82
#endif
82
#endif
83
 
83
 
84
#ifndef PRINT_list_ptr_ec
84
#ifndef PRINT_list_ptr_ec
85
static void PRINT_list_ptr_ec PROTO_S ( ( FILE *, LIST ( PTR ( ECONST ) ), char *, int ) ) ;
85
static void PRINT_list_ptr_ec (FILE *, LIST(PTR(ECONST)), char *, int);
86
#endif
86
#endif
87
 
87
 
88
#ifndef PRINT_list_ECONST_P
88
#ifndef PRINT_list_ECONST_P
89
#define PRINT_list_ECONST_P( A, B, C, D ) PRINT_list_ptr_ec ( ( A ), ( B ), ( C ), ( D ) )
89
#define PRINT_list_ECONST_P(A, B, C, D)PRINT_list_ptr_ec((A), (B), (C), (D))
90
#endif
90
#endif
91
 
91
 
92
#ifndef PRINT_alg
92
#ifndef PRINT_alg
93
static void PRINT_alg PROTO_S ( ( FILE *, ALGEBRA_DEFN, char *, int ) ) ;
93
static void PRINT_alg (FILE *, ALGEBRA_DEFN, char *, int);
94
#endif
94
#endif
95
 
95
 
96
#ifndef PRINT_list_ptr_type
96
#ifndef PRINT_list_ptr_type
97
static void PRINT_list_ptr_type PROTO_S ( ( FILE *, LIST ( PTR ( TYPE ) ), char *, int ) ) ;
97
static void PRINT_list_ptr_type (FILE *, LIST(PTR(TYPE)), char *, int);
98
#endif
98
#endif
99
 
99
 
100
#ifndef PRINT_list_TYPE_P
100
#ifndef PRINT_list_TYPE_P
101
#define PRINT_list_TYPE_P( A, B, C, D ) PRINT_list_ptr_type ( ( A ), ( B ), ( C ), ( D ) )
101
#define PRINT_list_TYPE_P(A, B, C, D)PRINT_list_ptr_type((A), (B), (C), (D))
102
#endif
102
#endif
103
 
103
 
104
#ifndef PRINT_list_ptr_un
104
#ifndef PRINT_list_ptr_un
105
static void PRINT_list_ptr_un PROTO_S ( ( FILE *, LIST ( PTR ( UNION ) ), char *, int ) ) ;
105
static void PRINT_list_ptr_un (FILE *, LIST(PTR(UNION)), char *, int);
106
#endif
106
#endif
107
 
107
 
108
#ifndef PRINT_list_UNION_P
108
#ifndef PRINT_list_UNION_P
109
#define PRINT_list_UNION_P( A, B, C, D ) PRINT_list_ptr_un ( ( A ), ( B ), ( C ), ( D ) )
109
#define PRINT_list_UNION_P(A, B, C, D)PRINT_list_ptr_un((A), (B), (C), (D))
110
#endif
110
#endif
111
 
111
 
112
#ifndef PRINT_list_ptr_str
112
#ifndef PRINT_list_ptr_str
113
static void PRINT_list_ptr_str PROTO_S ( ( FILE *, LIST ( PTR ( STRUCTURE ) ), char *, int ) ) ;
113
static void PRINT_list_ptr_str (FILE *, LIST(PTR(STRUCTURE)), char *, int);
114
#endif
114
#endif
115
 
115
 
116
#ifndef PRINT_list_STRUCTURE_P
116
#ifndef PRINT_list_STRUCTURE_P
117
#define PRINT_list_STRUCTURE_P( A, B, C, D ) PRINT_list_ptr_str ( ( A ), ( B ), ( C ), ( D ) )
117
#define PRINT_list_STRUCTURE_P(A, B, C, D)PRINT_list_ptr_str((A), (B), (C), (D))
118
#endif
118
#endif
119
 
119
 
120
#ifndef PRINT_list_ptr_en
120
#ifndef PRINT_list_ptr_en
121
static void PRINT_list_ptr_en PROTO_S ( ( FILE *, LIST ( PTR ( ENUM ) ), char *, int ) ) ;
121
static void PRINT_list_ptr_en (FILE *, LIST(PTR(ENUM)), char *, int);
122
#endif
122
#endif
123
 
123
 
124
#ifndef PRINT_list_ENUM_P
124
#ifndef PRINT_list_ENUM_P
125
#define PRINT_list_ENUM_P( A, B, C, D ) PRINT_list_ptr_en ( ( A ), ( B ), ( C ), ( D ) )
125
#define PRINT_list_ENUM_P(A, B, C, D)PRINT_list_ptr_en((A), (B), (C), (D))
126
#endif
126
#endif
127
 
127
 
128
#ifndef PRINT_list_ptr_ident
128
#ifndef PRINT_list_ptr_ident
129
static void PRINT_list_ptr_ident PROTO_S ( ( FILE *, LIST ( PTR ( IDENTITY ) ), char *, int ) ) ;
129
static void PRINT_list_ptr_ident (FILE *, LIST(PTR(IDENTITY)), char *, int);
130
#endif
130
#endif
131
 
131
 
132
#ifndef PRINT_list_IDENTITY_P
132
#ifndef PRINT_list_IDENTITY_P
133
#define PRINT_list_IDENTITY_P( A, B, C, D ) PRINT_list_ptr_ident ( ( A ), ( B ), ( C ), ( D ) )
133
#define PRINT_list_IDENTITY_P(A, B, C, D)PRINT_list_ptr_ident((A), (B), (C), (D))
134
#endif
134
#endif
135
 
135
 
136
#ifndef PRINT_list_ptr_prim
136
#ifndef PRINT_list_ptr_prim
137
static void PRINT_list_ptr_prim PROTO_S ( ( FILE *, LIST ( PTR ( PRIMITIVE ) ), char *, int ) ) ;
137
static void PRINT_list_ptr_prim (FILE *, LIST(PTR(PRIMITIVE)), char *, int);
138
#endif
138
#endif
139
 
139
 
140
#ifndef PRINT_list_PRIMITIVE_P
140
#ifndef PRINT_list_PRIMITIVE_P
141
#define PRINT_list_PRIMITIVE_P( A, B, C, D ) PRINT_list_ptr_prim ( ( A ), ( B ), ( C ), ( D ) )
141
#define PRINT_list_PRIMITIVE_P(A, B, C, D)PRINT_list_ptr_prim((A), (B), (C), (D))
142
#endif
142
#endif
143
 
143
 
144
#ifndef PRINT_UNION_P
144
#ifndef PRINT_UNION_P
145
#define PRINT_UNION_P( A, B, C, D ) PRINT_ptr_un ( ( A ), ( B ), ( C ), ( D ) )
145
#define PRINT_UNION_P(A, B, C, D)PRINT_ptr_un((A), (B), (C), (D))
146
#endif
146
#endif
147
 
147
 
148
#ifndef PRINT_ptr_un
148
#ifndef PRINT_ptr_un
149
static void PRINT_ptr_un PROTO_S ( ( FILE *, PTR ( UNION ), char *, int ) ) ;
149
static void PRINT_ptr_un (FILE *, PTR(UNION), char *, int);
150
#endif
150
#endif
151
 
151
 
152
#ifndef PRINT_un
152
#ifndef PRINT_un
153
static void PRINT_un PROTO_S ( ( FILE *, UNION, char *, int ) ) ;
153
static void PRINT_un (FILE *, UNION, char *, int);
154
#endif
154
#endif
155
 
155
 
156
#ifndef PRINT_TYPE_P_P
156
#ifndef PRINT_TYPE_P_P
157
#define PRINT_TYPE_P_P( A, B, C, D ) PRINT_ptr_TYPE_P ( ( A ), ( B ), ( C ), ( D ) )
157
#define PRINT_TYPE_P_P(A, B, C, D)PRINT_ptr_TYPE_P((A), (B), (C), (D))
158
#endif
158
#endif
159
 
159
 
160
#ifndef PRINT_ptr_ptr_type
160
#ifndef PRINT_ptr_ptr_type
161
static void PRINT_ptr_ptr_type PROTO_S ( ( FILE *, PTR ( PTR ( TYPE ) ), char *, int ) ) ;
161
static void PRINT_ptr_ptr_type (FILE *, PTR(PTR(TYPE)), char *, int);
162
#endif
162
#endif
163
 
163
 
164
#ifndef PRINT_ptr_TYPE_P
164
#ifndef PRINT_ptr_TYPE_P
165
#define PRINT_ptr_TYPE_P( A, B, C, D ) PRINT_ptr_ptr_type ( ( A ), ( B ), ( C ), ( D ) )
165
#define PRINT_ptr_TYPE_P(A, B, C, D)PRINT_ptr_ptr_type((A), (B), (C), (D))
166
#endif
166
#endif
167
 
167
 
168
#ifndef PRINT_TYPE_P
168
#ifndef PRINT_TYPE_P
169
#define PRINT_TYPE_P( A, B, C, D ) PRINT_ptr_type ( ( A ), ( B ), ( C ), ( D ) )
169
#define PRINT_TYPE_P(A, B, C, D)PRINT_ptr_type((A), (B), (C), (D))
170
#endif
170
#endif
171
 
171
 
172
#ifndef PRINT_ptr_type
172
#ifndef PRINT_ptr_type
173
static void PRINT_ptr_type PROTO_S ( ( FILE *, PTR ( TYPE ), char *, int ) ) ;
173
static void PRINT_ptr_type (FILE *, PTR(TYPE), char *, int);
174
#endif
174
#endif
175
 
175
 
176
#ifndef PRINT_type
176
#ifndef PRINT_type
177
static void PRINT_type PROTO_S ( ( FILE *, TYPE, char *, int ) ) ;
177
static void PRINT_type (FILE *, TYPE, char *, int);
178
#endif
178
#endif
179
 
179
 
180
#ifndef PRINT_STRUCTURE_P
180
#ifndef PRINT_STRUCTURE_P
181
#define PRINT_STRUCTURE_P( A, B, C, D ) PRINT_ptr_str ( ( A ), ( B ), ( C ), ( D ) )
181
#define PRINT_STRUCTURE_P(A, B, C, D)PRINT_ptr_str((A), (B), (C), (D))
182
#endif
182
#endif
183
 
183
 
184
#ifndef PRINT_ptr_str
184
#ifndef PRINT_ptr_str
185
static void PRINT_ptr_str PROTO_S ( ( FILE *, PTR ( STRUCTURE ), char *, int ) ) ;
185
static void PRINT_ptr_str (FILE *, PTR(STRUCTURE), char *, int);
186
#endif
186
#endif
187
 
187
 
188
#ifndef PRINT_str
188
#ifndef PRINT_str
189
static void PRINT_str PROTO_S ( ( FILE *, STRUCTURE, char *, int ) ) ;
189
static void PRINT_str (FILE *, STRUCTURE, char *, int);
190
#endif
190
#endif
191
 
191
 
192
#ifndef PRINT_PRIMITIVE_P
192
#ifndef PRINT_PRIMITIVE_P
193
#define PRINT_PRIMITIVE_P( A, B, C, D ) PRINT_ptr_prim ( ( A ), ( B ), ( C ), ( D ) )
193
#define PRINT_PRIMITIVE_P(A, B, C, D)PRINT_ptr_prim((A), (B), (C), (D))
194
#endif
194
#endif
195
 
195
 
196
#ifndef PRINT_ptr_prim
196
#ifndef PRINT_ptr_prim
197
static void PRINT_ptr_prim PROTO_S ( ( FILE *, PTR ( PRIMITIVE ), char *, int ) ) ;
197
static void PRINT_ptr_prim (FILE *, PTR(PRIMITIVE), char *, int);
198
#endif
198
#endif
199
 
199
 
200
#ifndef PRINT_prim
200
#ifndef PRINT_prim
201
static void PRINT_prim PROTO_S ( ( FILE *, PRIMITIVE, char *, int ) ) ;
201
static void PRINT_prim (FILE *, PRIMITIVE, char *, int);
202
#endif
202
#endif
203
 
203
 
204
#ifndef PRINT_MAP_P
204
#ifndef PRINT_MAP_P
205
#define PRINT_MAP_P( A, B, C, D ) PRINT_ptr_map ( ( A ), ( B ), ( C ), ( D ) )
205
#define PRINT_MAP_P(A, B, C, D)PRINT_ptr_map((A), (B), (C), (D))
206
#endif
206
#endif
207
 
207
 
208
#ifndef PRINT_ptr_map
208
#ifndef PRINT_ptr_map
209
static void PRINT_ptr_map PROTO_S ( ( FILE *, PTR ( MAP ), char *, int ) ) ;
209
static void PRINT_ptr_map (FILE *, PTR(MAP), char *, int);
210
#endif
210
#endif
211
 
211
 
212
#ifndef PRINT_map
212
#ifndef PRINT_map
213
static void PRINT_map PROTO_S ( ( FILE *, MAP, char *, int ) ) ;
213
static void PRINT_map (FILE *, MAP, char *, int);
214
#endif
214
#endif
215
 
215
 
216
#ifndef PRINT_IDENTITY_P
216
#ifndef PRINT_IDENTITY_P
217
#define PRINT_IDENTITY_P( A, B, C, D ) PRINT_ptr_ident ( ( A ), ( B ), ( C ), ( D ) )
217
#define PRINT_IDENTITY_P(A, B, C, D)PRINT_ptr_ident((A), (B), (C), (D))
218
#endif
218
#endif
219
 
219
 
220
#ifndef PRINT_ptr_ident
220
#ifndef PRINT_ptr_ident
221
static void PRINT_ptr_ident PROTO_S ( ( FILE *, PTR ( IDENTITY ), char *, int ) ) ;
221
static void PRINT_ptr_ident (FILE *, PTR(IDENTITY), char *, int);
222
#endif
222
#endif
223
 
223
 
224
#ifndef PRINT_ident
224
#ifndef PRINT_ident
225
static void PRINT_ident PROTO_S ( ( FILE *, IDENTITY, char *, int ) ) ;
225
static void PRINT_ident (FILE *, IDENTITY, char *, int);
226
#endif
226
#endif
227
 
227
 
228
#ifndef PRINT_FIELD_P
228
#ifndef PRINT_FIELD_P
229
#define PRINT_FIELD_P( A, B, C, D ) PRINT_ptr_fld ( ( A ), ( B ), ( C ), ( D ) )
229
#define PRINT_FIELD_P(A, B, C, D)PRINT_ptr_fld((A), (B), (C), (D))
230
#endif
230
#endif
231
 
231
 
232
#ifndef PRINT_ptr_fld
232
#ifndef PRINT_ptr_fld
233
static void PRINT_ptr_fld PROTO_S ( ( FILE *, PTR ( FIELD ), char *, int ) ) ;
233
static void PRINT_ptr_fld (FILE *, PTR(FIELD), char *, int);
234
#endif
234
#endif
235
 
235
 
236
#ifndef PRINT_fld
236
#ifndef PRINT_fld
237
static void PRINT_fld PROTO_S ( ( FILE *, FIELD, char *, int ) ) ;
237
static void PRINT_fld (FILE *, FIELD, char *, int);
238
#endif
238
#endif
239
 
239
 
240
#ifndef PRINT_ENUM_P
240
#ifndef PRINT_ENUM_P
241
#define PRINT_ENUM_P( A, B, C, D ) PRINT_ptr_en ( ( A ), ( B ), ( C ), ( D ) )
241
#define PRINT_ENUM_P(A, B, C, D)PRINT_ptr_en((A), (B), (C), (D))
242
#endif
242
#endif
243
 
243
 
244
#ifndef PRINT_ptr_en
244
#ifndef PRINT_ptr_en
245
static void PRINT_ptr_en PROTO_S ( ( FILE *, PTR ( ENUM ), char *, int ) ) ;
245
static void PRINT_ptr_en (FILE *, PTR(ENUM), char *, int);
246
#endif
246
#endif
247
 
247
 
248
#ifndef PRINT_en
248
#ifndef PRINT_en
249
static void PRINT_en PROTO_S ( ( FILE *, ENUM, char *, int ) ) ;
249
static void PRINT_en (FILE *, ENUM, char *, int);
250
#endif
250
#endif
251
 
251
 
252
#ifndef PRINT_ECONST_P
252
#ifndef PRINT_ECONST_P
253
#define PRINT_ECONST_P( A, B, C, D ) PRINT_ptr_ec ( ( A ), ( B ), ( C ), ( D ) )
253
#define PRINT_ECONST_P(A, B, C, D)PRINT_ptr_ec((A), (B), (C), (D))
254
#endif
254
#endif
255
 
255
 
256
#ifndef PRINT_ptr_ec
256
#ifndef PRINT_ptr_ec
257
static void PRINT_ptr_ec PROTO_S ( ( FILE *, PTR ( ECONST ), char *, int ) ) ;
257
static void PRINT_ptr_ec (FILE *, PTR(ECONST), char *, int);
258
#endif
258
#endif
259
 
259
 
260
#ifndef PRINT_ec
260
#ifndef PRINT_ec
261
static void PRINT_ec PROTO_S ( ( FILE *, ECONST, char *, int ) ) ;
261
static void PRINT_ec (FILE *, ECONST, char *, int);
262
#endif
262
#endif
263
 
263
 
264
#ifndef PRINT_COMPONENT_P
264
#ifndef PRINT_COMPONENT_P
265
#define PRINT_COMPONENT_P( A, B, C, D ) PRINT_ptr_cmp ( ( A ), ( B ), ( C ), ( D ) )
265
#define PRINT_COMPONENT_P(A, B, C, D)PRINT_ptr_cmp((A), (B), (C), (D))
266
#endif
266
#endif
267
 
267
 
268
#ifndef PRINT_ptr_cmp
268
#ifndef PRINT_ptr_cmp
269
static void PRINT_ptr_cmp PROTO_S ( ( FILE *, PTR ( COMPONENT ), char *, int ) ) ;
269
static void PRINT_ptr_cmp (FILE *, PTR(COMPONENT), char *, int);
270
#endif
270
#endif
271
 
271
 
272
#ifndef PRINT_cmp
272
#ifndef PRINT_cmp
273
static void PRINT_cmp PROTO_S ( ( FILE *, COMPONENT, char *, int ) ) ;
273
static void PRINT_cmp (FILE *, COMPONENT, char *, int);
274
#endif
274
#endif
275
 
275
 
276
#ifndef PRINT_CLASS_ID_P_P
276
#ifndef PRINT_CLASS_ID_P_P
277
#define PRINT_CLASS_ID_P_P( A, B, C, D ) PRINT_ptr_CLASS_ID_P ( ( A ), ( B ), ( C ), ( D ) )
277
#define PRINT_CLASS_ID_P_P(A, B, C, D)PRINT_ptr_CLASS_ID_P((A), (B), (C), (D))
278
#endif
278
#endif
279
 
279
 
280
#ifndef PRINT_ptr_ptr_cid
280
#ifndef PRINT_ptr_ptr_cid
281
static void PRINT_ptr_ptr_cid PROTO_S ( ( FILE *, PTR ( PTR ( CLASS_ID ) ), char *, int ) ) ;
281
static void PRINT_ptr_ptr_cid (FILE *, PTR(PTR(CLASS_ID)), char *, int);
282
#endif
282
#endif
283
 
283
 
284
#ifndef PRINT_ptr_CLASS_ID_P
284
#ifndef PRINT_ptr_CLASS_ID_P
285
#define PRINT_ptr_CLASS_ID_P( A, B, C, D ) PRINT_ptr_ptr_cid ( ( A ), ( B ), ( C ), ( D ) )
285
#define PRINT_ptr_CLASS_ID_P(A, B, C, D)PRINT_ptr_ptr_cid((A), (B), (C), (D))
286
#endif
286
#endif
287
 
287
 
288
#ifndef PRINT_CLASS_ID_P
288
#ifndef PRINT_CLASS_ID_P
289
#define PRINT_CLASS_ID_P( A, B, C, D ) PRINT_ptr_cid ( ( A ), ( B ), ( C ), ( D ) )
289
#define PRINT_CLASS_ID_P(A, B, C, D)PRINT_ptr_cid((A), (B), (C), (D))
290
#endif
290
#endif
291
 
291
 
292
#ifndef PRINT_ptr_cid
292
#ifndef PRINT_ptr_cid
293
static void PRINT_ptr_cid PROTO_S ( ( FILE *, PTR ( CLASS_ID ), char *, int ) ) ;
293
static void PRINT_ptr_cid (FILE *, PTR(CLASS_ID), char *, int);
294
#endif
294
#endif
295
 
295
 
296
#ifndef PRINT_cid
296
#ifndef PRINT_cid
297
static void PRINT_cid PROTO_S ( ( FILE *, CLASS_ID, char *, int ) ) ;
297
static void PRINT_cid (FILE *, CLASS_ID, char *, int);
298
#endif
298
#endif
299
 
299
 
300
#ifndef PRINT_ARGUMENT_P
300
#ifndef PRINT_ARGUMENT_P
301
#define PRINT_ARGUMENT_P( A, B, C, D ) PRINT_ptr_arg ( ( A ), ( B ), ( C ), ( D ) )
301
#define PRINT_ARGUMENT_P(A, B, C, D)PRINT_ptr_arg((A), (B), (C), (D))
302
#endif
302
#endif
303
 
303
 
304
#ifndef PRINT_ptr_arg
304
#ifndef PRINT_ptr_arg
305
static void PRINT_ptr_arg PROTO_S ( ( FILE *, PTR ( ARGUMENT ), char *, int ) ) ;
305
static void PRINT_ptr_arg (FILE *, PTR(ARGUMENT), char *, int);
306
#endif
306
#endif
307
 
307
 
308
#ifndef PRINT_arg
308
#ifndef PRINT_arg
309
static void PRINT_arg PROTO_S ( ( FILE *, ARGUMENT, char *, int ) ) ;
309
static void PRINT_arg (FILE *, ARGUMENT, char *, int);
310
#endif
310
#endif
311
 
311
 
312
#ifndef PRINT_string_P
312
#ifndef PRINT_string_P
313
#define PRINT_string_P( A, B, C, D ) PRINT_ptr_string ( ( A ), ( B ), ( C ), ( D ) )
313
#define PRINT_string_P(A, B, C, D)PRINT_ptr_string((A), (B), (C), (D))
314
#endif
314
#endif
315
 
315
 
316
#ifndef PRINT_ptr_string
316
#ifndef PRINT_ptr_string
317
static void PRINT_ptr_string PROTO_S ( ( FILE *, PTR ( string ), char *, int ) ) ;
317
static void PRINT_ptr_string (FILE *, PTR(string), char *, int);
318
#endif
318
#endif
319
 
319
 
320
#ifndef PRINT_number_P
320
#ifndef PRINT_number_P
321
#define PRINT_number_P( A, B, C, D ) PRINT_ptr_number ( ( A ), ( B ), ( C ), ( D ) )
321
#define PRINT_number_P(A, B, C, D)PRINT_ptr_number((A), (B), (C), (D))
322
#endif
322
#endif
323
 
323
 
324
#ifndef PRINT_ptr_number
324
#ifndef PRINT_ptr_number
325
static void PRINT_ptr_number PROTO_S ( ( FILE *, PTR ( number ), char *, int ) ) ;
325
static void PRINT_ptr_number (FILE *, PTR(number), char *, int);
326
#endif
326
#endif
327
 
327
 
328
#ifndef PRINT_int_P
328
#ifndef PRINT_int_P
329
#define PRINT_int_P( A, B, C, D ) PRINT_ptr_int ( ( A ), ( B ), ( C ), ( D ) )
329
#define PRINT_int_P(A, B, C, D)PRINT_ptr_int((A), (B), (C), (D))
330
#endif
330
#endif
331
 
331
 
332
#ifndef PRINT_ptr_int
332
#ifndef PRINT_ptr_int
333
static void PRINT_ptr_int PROTO_S ( ( FILE *, PTR ( int ), char *, int ) ) ;
333
static void PRINT_ptr_int (FILE *, PTR(int), char *, int);
334
#endif
334
#endif
335
 
335
 
336
#ifndef PRINT_zero_int
336
#ifndef PRINT_zero_int
337
#define PRINT_zero_int( A, B, C, D ) PRINT_int ( ( A ), ( B ), ( C ), ( D ) )
337
#define PRINT_zero_int(A, B, C, D)PRINT_int((A), (B), (C), (D))
338
#endif
338
#endif
339
 
339
 
340
#ifndef PRINT_name_string
340
#ifndef PRINT_name_string
341
#define PRINT_name_string( A, B, C, D ) PRINT_string ( ( A ), ( B ), ( C ), ( D ) )
341
#define PRINT_name_string(A, B, C, D)PRINT_string((A), (B), (C), (D))
342
#endif
342
#endif
343
 
343
 
344
#ifndef PRINT_string
344
#ifndef PRINT_string
345
static void PRINT_string PROTO_S ( ( FILE *, string, char *, int ) ) ;
345
static void PRINT_string (FILE *, string, char *, int);
346
#endif
346
#endif
347
 
347
 
348
#ifndef PRINT_number
348
#ifndef PRINT_number
349
static void PRINT_number PROTO_S ( ( FILE *, number, char *, int ) ) ;
349
static void PRINT_number (FILE *, number, char *, int);
350
#endif
350
#endif
351
 
351
 
352
#ifndef PRINT_int
352
#ifndef PRINT_int
353
static void PRINT_int PROTO_S ( ( FILE *, int, char *, int ) ) ;
353
static void PRINT_int (FILE *, int, char *, int);
354
#endif
354
#endif
355
 
355
 
356
 
356
 
357
 
357
 
358
/* Printing variables */
358
/* Printing variables */
359
 
359
 
360
static int print_indent_step = 4 ;
360
static int print_indent_step = 4;
361
static int print_ptr_depth = 1 ;
361
static int print_ptr_depth = 1;
362
static int print_list_expand = 0 ;
362
static int print_list_expand = 0;
363
 
363
 
364
 
364
 
365
/* Printing indentation routine */
365
/* Printing indentation routine */
366
 
366
 
367
static void print_indent
367
static void print_indent
368
    PROTO_N ( ( f, d ) )
-
 
-
 
368
 
369
    PROTO_T ( FILE *f X int d )
369
(FILE *f, int d)
370
{
370
{
371
    int i = print_indent_step * d ;
371
    int i = print_indent_step * d;
372
    while ( i-- ) ( void ) fputc ( ' ', f ) ;
372
    while (i--) (void)fputc(' ', f);
373
    return ;
373
    return;
374
}
374
}
375
 
375
 
376
 
376
 
377
/* Printing routines for LIST ( COMMAND ) */
377
/* Printing routines for LIST(COMMAND) */
378
 
378
 
379
#ifndef PRINT_list_cmd
379
#ifndef PRINT_list_cmd
380
 
380
 
381
static void PRINT_list_cmd
381
static void
382
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
383
    PROTO_T ( FILE *f_ X LIST ( COMMAND ) x_ X char *nm_ X int d_ )
382
PRINT_list_cmd(FILE *f_, LIST(COMMAND) x_, char *nm_, int d_)
384
{
383
{
385
    print_indent ( f_, d_ ) ;
384
    print_indent(f_, d_);
386
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
385
    (void)fprintf(f_, "%s = LIST {\n", nm_);
387
    while ( !IS_NULL_list ( x_ ) ) {
386
    while (!IS_NULL_list(x_)) {
388
	COMMAND z_ ;
387
	COMMAND z_;
389
	UN_CONS_cmd ( z_, x_, x_ ) ;
388
	UN_CONS_cmd(z_, x_, x_);
390
	PRINT_cmd ( f_, z_, "(cmd)", d_ + 1 ) ;
389
	PRINT_cmd(f_, z_, "(cmd)", d_ + 1);
391
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
390
	if (!print_list_expand && !IS_NULL_list(x_)) {
392
	    print_indent ( f_, d_ + 1 ) ;
391
	    print_indent(f_, d_ + 1);
393
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
392
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
394
	    break ;
393
	    break;
395
	}
394
	}
396
    }
395
    }
397
    print_indent ( f_, d_ ) ;
396
    print_indent(f_, d_);
398
    ( void ) fprintf ( f_, "}\n" ) ;
397
    (void)fprintf(f_, "}\n");
399
    return ;
398
    return;
400
}
399
}
401
 
400
 
402
#ifdef DEBUG
401
#ifdef DEBUG
403
 
402
 
404
void DEBUG_list_cmd
403
void
405
    PROTO_N ( ( x_ ) )
-
 
406
    PROTO_T ( LIST ( COMMAND ) x_ )
404
DEBUG_list_cmd(LIST(COMMAND) x_)
407
{
405
{
408
    PRINT_list_cmd ( stdout, x_, "list_cmd", 0 ) ;
406
    PRINT_list_cmd(stdout, x_, "list_cmd", 0);
409
    return ;
407
    return;
410
}
408
}
411
 
409
 
412
#endif
410
#endif
413
 
411
 
414
#endif
412
#endif
Line 416... Line 414...
416
 
414
 
417
/* Printing routines for COMMAND */
415
/* Printing routines for COMMAND */
418
 
416
 
419
#ifndef PRINT_cmd
417
#ifndef PRINT_cmd
420
 
418
 
421
static void PRINT_cmd
419
static void
422
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
423
    PROTO_T ( FILE *f_ X COMMAND x_ X char *nm_ X int d_ )
420
PRINT_cmd(FILE *f_, COMMAND x_, char *nm_, int d_)
424
{
421
{
425
    print_indent ( f_, d_ ) ;
422
    print_indent(f_, d_);
426
    if ( IS_NULL_cmd ( x_ ) ) {
423
    if (IS_NULL_cmd(x_)) {
427
	( void ) fprintf ( f_, "%s = NULL_cmd ;\n", nm_ ) ;
424
	(void)fprintf(f_, "%s = NULL_cmd ;\n", nm_);
428
    } else {
425
    } else {
429
	switch ( TAG_cmd ( x_ ) ) {
426
	switch (TAG_cmd(x_)) {
430
	    case cmd_simple_tag : {
427
	    case cmd_simple_tag: {
431
		( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
428
		(void)fprintf(f_, "%s = {\n", nm_);
432
		print_indent ( f_, d_ + 1 ) ;
429
		print_indent(f_, d_ + 1);
433
		( void ) fprintf ( f_, "(tag) = simple ;\n" ) ;
430
		(void)fprintf(f_, "(tag) = simple ;\n");
434
		{
431
		{
435
		    int z_ ;
432
		    int z_;
436
		    z_ = DEREF_int ( cmd_line ( x_ ) ) ;
433
		    z_ = DEREF_int(cmd_line(x_));
437
		    PRINT_int ( f_, z_, "line", d_ + 1 ) ;
434
		    PRINT_int(f_, z_, "line", d_ + 1);
438
		}
435
		}
439
		{
436
		{
440
		    string z_ ;
437
		    string z_;
441
		    z_ = DEREF_string ( cmd_simple_text ( x_ ) ) ;
438
		    z_ = DEREF_string(cmd_simple_text(x_));
442
		    PRINT_string ( f_, z_, "text", d_ + 1 ) ;
439
		    PRINT_string(f_, z_, "text", d_ + 1);
443
		}
440
		}
444
		print_indent ( f_, d_ ) ;
441
		print_indent(f_, d_);
445
		( void ) fprintf ( f_, "}\n" ) ;
442
		(void)fprintf(f_, "}\n");
446
		break ;
443
		break;
447
	    }
444
	    }
448
	    case cmd_compound_tag : {
445
	    case cmd_compound_tag: {
449
		( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
446
		(void)fprintf(f_, "%s = {\n", nm_);
450
		print_indent ( f_, d_ + 1 ) ;
447
		print_indent(f_, d_ + 1);
451
		( void ) fprintf ( f_, "(tag) = compound ;\n" ) ;
448
		(void)fprintf(f_, "(tag) = compound ;\n");
452
		{
449
		{
453
		    int z_ ;
450
		    int z_;
454
		    z_ = DEREF_int ( cmd_line ( x_ ) ) ;
451
		    z_ = DEREF_int(cmd_line(x_));
455
		    PRINT_int ( f_, z_, "line", d_ + 1 ) ;
452
		    PRINT_int(f_, z_, "line", d_ + 1);
456
		}
453
		}
457
		{
454
		{
458
		    LIST ( COMMAND ) z_ ;
455
		    LIST(COMMAND) z_;
459
		    z_ = DEREF_list ( cmd_compound_seq ( x_ ) ) ;
456
		    z_ = DEREF_list(cmd_compound_seq(x_));
460
		    PRINT_list_cmd ( f_, z_, "seq", d_ + 1 ) ;
457
		    PRINT_list_cmd(f_, z_, "seq", d_ + 1);
461
		}
458
		}
462
		print_indent ( f_, d_ ) ;
459
		print_indent(f_, d_);
463
		( void ) fprintf ( f_, "}\n" ) ;
460
		(void)fprintf(f_, "}\n");
464
		break ;
461
		break;
465
	    }
462
	    }
466
	    case cmd_loop_tag : {
463
	    case cmd_loop_tag: {
467
		( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
464
		(void)fprintf(f_, "%s = {\n", nm_);
468
		print_indent ( f_, d_ + 1 ) ;
465
		print_indent(f_, d_ + 1);
469
		( void ) fprintf ( f_, "(tag) = loop ;\n" ) ;
466
		(void)fprintf(f_, "(tag) = loop ;\n");
470
		{
467
		{
471
		    int z_ ;
468
		    int z_;
472
		    z_ = DEREF_int ( cmd_line ( x_ ) ) ;
469
		    z_ = DEREF_int(cmd_line(x_));
473
		    PRINT_int ( f_, z_, "line", d_ + 1 ) ;
470
		    PRINT_int(f_, z_, "line", d_ + 1);
474
		}
471
		}
475
		{
472
		{
476
		    string z_ ;
473
		    string z_;
477
		    z_ = DEREF_string ( cmd_loop_control ( x_ ) ) ;
474
		    z_ = DEREF_string(cmd_loop_control(x_));
478
		    PRINT_string ( f_, z_, "control", d_ + 1 ) ;
475
		    PRINT_string(f_, z_, "control", d_ + 1);
479
		}
476
		}
480
		{
477
		{
481
		    COMMAND z_ ;
478
		    COMMAND z_;
482
		    z_ = DEREF_cmd ( cmd_loop_body ( x_ ) ) ;
479
		    z_ = DEREF_cmd(cmd_loop_body(x_));
483
		    PRINT_cmd ( f_, z_, "body", d_ + 1 ) ;
480
		    PRINT_cmd(f_, z_, "body", d_ + 1);
484
		}
481
		}
485
		print_indent ( f_, d_ ) ;
482
		print_indent(f_, d_);
486
		( void ) fprintf ( f_, "}\n" ) ;
483
		(void)fprintf(f_, "}\n");
487
		break ;
484
		break;
488
	    }
485
	    }
489
	    case cmd_cond_tag : {
486
	    case cmd_cond_tag: {
490
		( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
487
		(void)fprintf(f_, "%s = {\n", nm_);
491
		print_indent ( f_, d_ + 1 ) ;
488
		print_indent(f_, d_ + 1);
492
		( void ) fprintf ( f_, "(tag) = cond ;\n" ) ;
489
		(void)fprintf(f_, "(tag) = cond ;\n");
493
		{
490
		{
494
		    int z_ ;
491
		    int z_;
495
		    z_ = DEREF_int ( cmd_line ( x_ ) ) ;
492
		    z_ = DEREF_int(cmd_line(x_));
496
		    PRINT_int ( f_, z_, "line", d_ + 1 ) ;
493
		    PRINT_int(f_, z_, "line", d_ + 1);
497
		}
494
		}
498
		{
495
		{
499
		    string z_ ;
496
		    string z_;
500
		    z_ = DEREF_string ( cmd_cond_control ( x_ ) ) ;
497
		    z_ = DEREF_string(cmd_cond_control(x_));
501
		    PRINT_string ( f_, z_, "control", d_ + 1 ) ;
498
		    PRINT_string(f_, z_, "control", d_ + 1);
502
		}
499
		}
503
		{
500
		{
504
		    COMMAND z_ ;
501
		    COMMAND z_;
505
		    z_ = DEREF_cmd ( cmd_cond_true_code ( x_ ) ) ;
502
		    z_ = DEREF_cmd(cmd_cond_true_code(x_));
506
		    PRINT_cmd ( f_, z_, "true_code", d_ + 1 ) ;
503
		    PRINT_cmd(f_, z_, "true_code", d_ + 1);
507
		}
504
		}
508
		{
505
		{
509
		    COMMAND z_ ;
506
		    COMMAND z_;
510
		    z_ = DEREF_cmd ( cmd_cond_false_code ( x_ ) ) ;
507
		    z_ = DEREF_cmd(cmd_cond_false_code(x_));
511
		    PRINT_cmd ( f_, z_, "false_code", d_ + 1 ) ;
508
		    PRINT_cmd(f_, z_, "false_code", d_ + 1);
512
		}
509
		}
513
		print_indent ( f_, d_ ) ;
510
		print_indent(f_, d_);
514
		( void ) fprintf ( f_, "}\n" ) ;
511
		(void)fprintf(f_, "}\n");
515
		break ;
512
		break;
516
	    }
513
	    }
517
	    default : {
514
	    default : {
518
		( void ) fprintf ( f_, "%s = ERROR!\n", nm_ ) ;
515
		(void)fprintf(f_, "%s = ERROR!\n", nm_);
519
		break ;
516
		break;
520
	    }
517
	    }
521
	}
518
	}
522
    }
519
    }
523
    return ;
520
    return;
524
}
521
}
525
 
522
 
526
#ifdef DEBUG
523
#ifdef DEBUG
527
 
524
 
528
void DEBUG_cmd
525
void
529
    PROTO_N ( ( x_ ) )
-
 
530
    PROTO_T ( COMMAND x_ )
526
DEBUG_cmd(COMMAND x_)
531
{
527
{
532
    PRINT_cmd ( stdout, x_, "cmd", 0 ) ;
528
    PRINT_cmd(stdout, x_, "cmd", 0);
533
    return ;
529
    return;
534
}
530
}
535
 
531
 
536
#endif
532
#endif
537
 
533
 
538
#endif
534
#endif
539
 
535
 
540
 
536
 
541
/* Printing routines for LIST ( PTR ( MAP ) ) */
537
/* Printing routines for LIST(PTR(MAP)) */
542
 
538
 
543
#ifndef PRINT_list_ptr_map
539
#ifndef PRINT_list_ptr_map
544
 
540
 
545
static void PRINT_list_ptr_map
541
static void
546
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
547
    PROTO_T ( FILE *f_ X LIST ( PTR ( MAP ) ) x_ X char *nm_ X int d_ )
542
PRINT_list_ptr_map(FILE *f_, LIST(PTR(MAP)) x_, char *nm_, int d_)
548
{
543
{
549
    print_indent ( f_, d_ ) ;
544
    print_indent(f_, d_);
550
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
545
    (void)fprintf(f_, "%s = LIST {\n", nm_);
551
    while ( !IS_NULL_list ( x_ ) ) {
546
    while (!IS_NULL_list(x_)) {
552
	PTR ( MAP ) z_ ;
547
	PTR(MAP) z_;
553
	UN_CONS_ptr ( z_, x_, x_ ) ;
548
	UN_CONS_ptr(z_, x_, x_);
554
	PRINT_ptr_map ( f_, z_, "(ptr_map)", d_ + 1 ) ;
549
	PRINT_ptr_map(f_, z_, "(ptr_map)", d_ + 1);
555
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
550
	if (!print_list_expand && !IS_NULL_list(x_)) {
556
	    print_indent ( f_, d_ + 1 ) ;
551
	    print_indent(f_, d_ + 1);
557
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
552
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
558
	    break ;
553
	    break;
559
	}
554
	}
560
    }
555
    }
561
    print_indent ( f_, d_ ) ;
556
    print_indent(f_, d_);
562
    ( void ) fprintf ( f_, "}\n" ) ;
557
    (void)fprintf(f_, "}\n");
563
    return ;
558
    return;
564
}
559
}
565
 
560
 
566
#ifdef DEBUG
561
#ifdef DEBUG
567
 
562
 
568
void DEBUG_list_ptr_map
563
void
569
    PROTO_N ( ( x_ ) )
-
 
570
    PROTO_T ( LIST ( PTR ( MAP ) ) x_ )
564
DEBUG_list_ptr_map(LIST(PTR(MAP)) x_)
571
{
565
{
572
    PRINT_list_ptr_map ( stdout, x_, "list_ptr_map", 0 ) ;
566
    PRINT_list_ptr_map(stdout, x_, "list_ptr_map", 0);
573
    return ;
567
    return;
574
}
568
}
575
 
569
 
576
#endif
570
#endif
577
 
571
 
578
#endif
572
#endif
579
 
573
 
580
 
574
 
581
/* Printing routines for LIST ( PTR ( FIELD ) ) */
575
/* Printing routines for LIST(PTR(FIELD)) */
582
 
576
 
583
#ifndef PRINT_list_ptr_fld
577
#ifndef PRINT_list_ptr_fld
584
 
578
 
585
static void PRINT_list_ptr_fld
579
static void
586
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
587
    PROTO_T ( FILE *f_ X LIST ( PTR ( FIELD ) ) x_ X char *nm_ X int d_ )
580
PRINT_list_ptr_fld(FILE *f_, LIST(PTR(FIELD)) x_, char *nm_, int d_)
588
{
581
{
589
    print_indent ( f_, d_ ) ;
582
    print_indent(f_, d_);
590
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
583
    (void)fprintf(f_, "%s = LIST {\n", nm_);
591
    while ( !IS_NULL_list ( x_ ) ) {
584
    while (!IS_NULL_list(x_)) {
592
	PTR ( FIELD ) z_ ;
585
	PTR(FIELD) z_;
593
	UN_CONS_ptr ( z_, x_, x_ ) ;
586
	UN_CONS_ptr(z_, x_, x_);
594
	PRINT_ptr_fld ( f_, z_, "(ptr_fld)", d_ + 1 ) ;
587
	PRINT_ptr_fld(f_, z_, "(ptr_fld)", d_ + 1);
595
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
588
	if (!print_list_expand && !IS_NULL_list(x_)) {
596
	    print_indent ( f_, d_ + 1 ) ;
589
	    print_indent(f_, d_ + 1);
597
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
590
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
598
	    break ;
591
	    break;
599
	}
592
	}
600
    }
593
    }
601
    print_indent ( f_, d_ ) ;
594
    print_indent(f_, d_);
602
    ( void ) fprintf ( f_, "}\n" ) ;
595
    (void)fprintf(f_, "}\n");
603
    return ;
596
    return;
604
}
597
}
605
 
598
 
606
#ifdef DEBUG
599
#ifdef DEBUG
607
 
600
 
608
void DEBUG_list_ptr_fld
601
void
609
    PROTO_N ( ( x_ ) )
-
 
610
    PROTO_T ( LIST ( PTR ( FIELD ) ) x_ )
602
DEBUG_list_ptr_fld(LIST(PTR(FIELD)) x_)
611
{
603
{
612
    PRINT_list_ptr_fld ( stdout, x_, "list_ptr_fld", 0 ) ;
604
    PRINT_list_ptr_fld(stdout, x_, "list_ptr_fld", 0);
613
    return ;
605
    return;
614
}
606
}
615
 
607
 
616
#endif
608
#endif
617
 
609
 
618
#endif
610
#endif
619
 
611
 
620
 
612
 
621
/* Printing routines for LIST ( PTR ( ARGUMENT ) ) */
613
/* Printing routines for LIST(PTR(ARGUMENT)) */
622
 
614
 
623
#ifndef PRINT_list_ptr_arg
615
#ifndef PRINT_list_ptr_arg
624
 
616
 
625
static void PRINT_list_ptr_arg
617
static void
626
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
627
    PROTO_T ( FILE *f_ X LIST ( PTR ( ARGUMENT ) ) x_ X char *nm_ X int d_ )
618
PRINT_list_ptr_arg(FILE *f_, LIST(PTR(ARGUMENT)) x_, char *nm_, int d_)
628
{
619
{
629
    print_indent ( f_, d_ ) ;
620
    print_indent(f_, d_);
630
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
621
    (void)fprintf(f_, "%s = LIST {\n", nm_);
631
    while ( !IS_NULL_list ( x_ ) ) {
622
    while (!IS_NULL_list(x_)) {
632
	PTR ( ARGUMENT ) z_ ;
623
	PTR(ARGUMENT) z_;
633
	UN_CONS_ptr ( z_, x_, x_ ) ;
624
	UN_CONS_ptr(z_, x_, x_);
634
	PRINT_ptr_arg ( f_, z_, "(ptr_arg)", d_ + 1 ) ;
625
	PRINT_ptr_arg(f_, z_, "(ptr_arg)", d_ + 1);
635
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
626
	if (!print_list_expand && !IS_NULL_list(x_)) {
636
	    print_indent ( f_, d_ + 1 ) ;
627
	    print_indent(f_, d_ + 1);
637
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
628
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
638
	    break ;
629
	    break;
639
	}
630
	}
640
    }
631
    }
641
    print_indent ( f_, d_ ) ;
632
    print_indent(f_, d_);
642
    ( void ) fprintf ( f_, "}\n" ) ;
633
    (void)fprintf(f_, "}\n");
643
    return ;
634
    return;
644
}
635
}
645
 
636
 
646
#ifdef DEBUG
637
#ifdef DEBUG
647
 
638
 
648
void DEBUG_list_ptr_arg
639
void
649
    PROTO_N ( ( x_ ) )
-
 
650
    PROTO_T ( LIST ( PTR ( ARGUMENT ) ) x_ )
640
DEBUG_list_ptr_arg(LIST(PTR(ARGUMENT)) x_)
651
{
641
{
652
    PRINT_list_ptr_arg ( stdout, x_, "list_ptr_arg", 0 ) ;
642
    PRINT_list_ptr_arg(stdout, x_, "list_ptr_arg", 0);
653
    return ;
643
    return;
654
}
644
}
655
 
645
 
656
#endif
646
#endif
657
 
647
 
658
#endif
648
#endif
659
 
649
 
660
 
650
 
661
/* Printing routines for LIST ( PTR ( COMPONENT ) ) */
651
/* Printing routines for LIST(PTR(COMPONENT)) */
662
 
652
 
663
#ifndef PRINT_list_ptr_cmp
653
#ifndef PRINT_list_ptr_cmp
664
 
654
 
665
static void PRINT_list_ptr_cmp
655
static void
666
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
667
    PROTO_T ( FILE *f_ X LIST ( PTR ( COMPONENT ) ) x_ X char *nm_ X int d_ )
656
PRINT_list_ptr_cmp(FILE *f_, LIST(PTR(COMPONENT)) x_, char *nm_, int d_)
668
{
657
{
669
    print_indent ( f_, d_ ) ;
658
    print_indent(f_, d_);
670
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
659
    (void)fprintf(f_, "%s = LIST {\n", nm_);
671
    while ( !IS_NULL_list ( x_ ) ) {
660
    while (!IS_NULL_list(x_)) {
672
	PTR ( COMPONENT ) z_ ;
661
	PTR(COMPONENT) z_;
673
	UN_CONS_ptr ( z_, x_, x_ ) ;
662
	UN_CONS_ptr(z_, x_, x_);
674
	PRINT_ptr_cmp ( f_, z_, "(ptr_cmp)", d_ + 1 ) ;
663
	PRINT_ptr_cmp(f_, z_, "(ptr_cmp)", d_ + 1);
675
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
664
	if (!print_list_expand && !IS_NULL_list(x_)) {
676
	    print_indent ( f_, d_ + 1 ) ;
665
	    print_indent(f_, d_ + 1);
677
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
666
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
678
	    break ;
667
	    break;
679
	}
668
	}
680
    }
669
    }
681
    print_indent ( f_, d_ ) ;
670
    print_indent(f_, d_);
682
    ( void ) fprintf ( f_, "}\n" ) ;
671
    (void)fprintf(f_, "}\n");
683
    return ;
672
    return;
684
}
673
}
685
 
674
 
686
#ifdef DEBUG
675
#ifdef DEBUG
687
 
676
 
688
void DEBUG_list_ptr_cmp
677
void
689
    PROTO_N ( ( x_ ) )
-
 
690
    PROTO_T ( LIST ( PTR ( COMPONENT ) ) x_ )
678
DEBUG_list_ptr_cmp(LIST(PTR(COMPONENT)) x_)
691
{
679
{
692
    PRINT_list_ptr_cmp ( stdout, x_, "list_ptr_cmp", 0 ) ;
680
    PRINT_list_ptr_cmp(stdout, x_, "list_ptr_cmp", 0);
693
    return ;
681
    return;
694
}
682
}
695
 
683
 
696
#endif
684
#endif
697
 
685
 
698
#endif
686
#endif
699
 
687
 
700
 
688
 
701
/* Printing routines for LIST ( PTR ( ECONST ) ) */
689
/* Printing routines for LIST(PTR(ECONST)) */
702
 
690
 
703
#ifndef PRINT_list_ptr_ec
691
#ifndef PRINT_list_ptr_ec
704
 
692
 
705
static void PRINT_list_ptr_ec
693
static void
706
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
707
    PROTO_T ( FILE *f_ X LIST ( PTR ( ECONST ) ) x_ X char *nm_ X int d_ )
694
PRINT_list_ptr_ec(FILE *f_, LIST(PTR(ECONST)) x_, char *nm_, int d_)
708
{
695
{
709
    print_indent ( f_, d_ ) ;
696
    print_indent(f_, d_);
710
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
697
    (void)fprintf(f_, "%s = LIST {\n", nm_);
711
    while ( !IS_NULL_list ( x_ ) ) {
698
    while (!IS_NULL_list(x_)) {
712
	PTR ( ECONST ) z_ ;
699
	PTR(ECONST) z_;
713
	UN_CONS_ptr ( z_, x_, x_ ) ;
700
	UN_CONS_ptr(z_, x_, x_);
714
	PRINT_ptr_ec ( f_, z_, "(ptr_ec)", d_ + 1 ) ;
701
	PRINT_ptr_ec(f_, z_, "(ptr_ec)", d_ + 1);
715
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
702
	if (!print_list_expand && !IS_NULL_list(x_)) {
716
	    print_indent ( f_, d_ + 1 ) ;
703
	    print_indent(f_, d_ + 1);
717
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
704
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
718
	    break ;
705
	    break;
719
	}
706
	}
720
    }
707
    }
721
    print_indent ( f_, d_ ) ;
708
    print_indent(f_, d_);
722
    ( void ) fprintf ( f_, "}\n" ) ;
709
    (void)fprintf(f_, "}\n");
723
    return ;
710
    return;
724
}
711
}
725
 
712
 
726
#ifdef DEBUG
713
#ifdef DEBUG
727
 
714
 
728
void DEBUG_list_ptr_ec
715
void
729
    PROTO_N ( ( x_ ) )
-
 
730
    PROTO_T ( LIST ( PTR ( ECONST ) ) x_ )
716
DEBUG_list_ptr_ec(LIST(PTR(ECONST)) x_)
731
{
717
{
732
    PRINT_list_ptr_ec ( stdout, x_, "list_ptr_ec", 0 ) ;
718
    PRINT_list_ptr_ec(stdout, x_, "list_ptr_ec", 0);
733
    return ;
719
    return;
734
}
720
}
735
 
721
 
736
#endif
722
#endif
737
 
723
 
738
#endif
724
#endif
Line 740... Line 726...
740
 
726
 
741
/* Printing routines for ALGEBRA_DEFN */
727
/* Printing routines for ALGEBRA_DEFN */
742
 
728
 
743
#ifndef PRINT_alg
729
#ifndef PRINT_alg
744
 
730
 
745
static void PRINT_alg
731
static void
746
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
747
    PROTO_T ( FILE *f_ X ALGEBRA_DEFN x_ X char *nm_ X int d_ )
732
PRINT_alg(FILE *f_, ALGEBRA_DEFN x_, char *nm_, int d_)
748
{
733
{
749
    print_indent ( f_, d_ ) ;
734
    print_indent(f_, d_);
750
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
735
    (void)fprintf(f_, "%s = {\n", nm_);
751
    PRINT_string ( f_, x_.name, "name", d_ + 1 ) ;
736
    PRINT_string(f_, x_.name, "name", d_ + 1);
752
    PRINT_int ( f_, x_.major_no, "major_no", d_ + 1 ) ;
737
    PRINT_int(f_, x_.major_no, "major_no", d_ + 1);
753
    PRINT_int ( f_, x_.minor_no, "minor_no", d_ + 1 ) ;
738
    PRINT_int(f_, x_.minor_no, "minor_no", d_ + 1);
754
    PRINT_list_PRIMITIVE_P ( f_, x_.primitives, "primitives", d_ + 1 ) ;
739
    PRINT_list_PRIMITIVE_P(f_, x_.primitives, "primitives", d_ + 1);
755
    PRINT_list_IDENTITY_P ( f_, x_.identities, "identities", d_ + 1 ) ;
740
    PRINT_list_IDENTITY_P(f_, x_.identities, "identities", d_ + 1);
756
    PRINT_list_ENUM_P ( f_, x_.enumerations, "enumerations", d_ + 1 ) ;
741
    PRINT_list_ENUM_P(f_, x_.enumerations, "enumerations", d_ + 1);
757
    PRINT_list_STRUCTURE_P ( f_, x_.structures, "structures", d_ + 1 ) ;
742
    PRINT_list_STRUCTURE_P(f_, x_.structures, "structures", d_ + 1);
758
    PRINT_list_UNION_P ( f_, x_.unions, "unions", d_ + 1 ) ;
743
    PRINT_list_UNION_P(f_, x_.unions, "unions", d_ + 1);
759
    PRINT_list_TYPE_P ( f_, x_.types, "types", d_ + 1 ) ;
744
    PRINT_list_TYPE_P(f_, x_.types, "types", d_ + 1);
760
    print_indent ( f_, d_ ) ;
745
    print_indent(f_, d_);
761
    ( void ) fprintf ( f_, "}\n" ) ;
746
    (void)fprintf(f_, "}\n");
762
    return ;
747
    return;
763
}
748
}
764
 
749
 
765
#ifdef DEBUG
750
#ifdef DEBUG
766
 
751
 
767
void DEBUG_alg
752
void
768
    PROTO_N ( ( x_ ) )
-
 
769
    PROTO_T ( ALGEBRA_DEFN *x_ )
753
DEBUG_alg(ALGEBRA_DEFN *x_)
770
{
754
{
771
    if ( x_ ) PRINT_alg ( stdout, *x_, "alg", 0 ) ;
755
    if (x_)PRINT_alg(stdout, *x_, "alg", 0);
772
    return ;
756
    return;
773
}
757
}
774
 
758
 
775
#endif
759
#endif
776
 
760
 
777
#endif
761
#endif
778
 
762
 
779
 
763
 
780
/* Printing routines for LIST ( PTR ( TYPE ) ) */
764
/* Printing routines for LIST(PTR(TYPE)) */
781
 
765
 
782
#ifndef PRINT_list_ptr_type
766
#ifndef PRINT_list_ptr_type
783
 
767
 
784
static void PRINT_list_ptr_type
768
static void
785
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
786
    PROTO_T ( FILE *f_ X LIST ( PTR ( TYPE ) ) x_ X char *nm_ X int d_ )
769
PRINT_list_ptr_type(FILE *f_, LIST(PTR(TYPE)) x_, char *nm_, int d_)
787
{
770
{
788
    print_indent ( f_, d_ ) ;
771
    print_indent(f_, d_);
789
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
772
    (void)fprintf(f_, "%s = LIST {\n", nm_);
790
    while ( !IS_NULL_list ( x_ ) ) {
773
    while (!IS_NULL_list(x_)) {
791
	PTR ( TYPE ) z_ ;
774
	PTR(TYPE) z_;
792
	UN_CONS_ptr ( z_, x_, x_ ) ;
775
	UN_CONS_ptr(z_, x_, x_);
793
	PRINT_ptr_type ( f_, z_, "(ptr_type)", d_ + 1 ) ;
776
	PRINT_ptr_type(f_, z_, "(ptr_type)", d_ + 1);
794
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
777
	if (!print_list_expand && !IS_NULL_list(x_)) {
795
	    print_indent ( f_, d_ + 1 ) ;
778
	    print_indent(f_, d_ + 1);
796
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
779
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
797
	    break ;
780
	    break;
798
	}
781
	}
799
    }
782
    }
800
    print_indent ( f_, d_ ) ;
783
    print_indent(f_, d_);
801
    ( void ) fprintf ( f_, "}\n" ) ;
784
    (void)fprintf(f_, "}\n");
802
    return ;
785
    return;
803
}
786
}
804
 
787
 
805
#ifdef DEBUG
788
#ifdef DEBUG
806
 
789
 
807
void DEBUG_list_ptr_type
790
void
808
    PROTO_N ( ( x_ ) )
-
 
809
    PROTO_T ( LIST ( PTR ( TYPE ) ) x_ )
791
DEBUG_list_ptr_type(LIST(PTR(TYPE)) x_)
810
{
792
{
811
    PRINT_list_ptr_type ( stdout, x_, "list_ptr_type", 0 ) ;
793
    PRINT_list_ptr_type(stdout, x_, "list_ptr_type", 0);
812
    return ;
794
    return;
813
}
795
}
814
 
796
 
815
#endif
797
#endif
816
 
798
 
817
#endif
799
#endif
818
 
800
 
819
 
801
 
820
/* Printing routines for LIST ( PTR ( UNION ) ) */
802
/* Printing routines for LIST(PTR(UNION)) */
821
 
803
 
822
#ifndef PRINT_list_ptr_un
804
#ifndef PRINT_list_ptr_un
823
 
805
 
824
static void PRINT_list_ptr_un
806
static void
825
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
826
    PROTO_T ( FILE *f_ X LIST ( PTR ( UNION ) ) x_ X char *nm_ X int d_ )
807
PRINT_list_ptr_un(FILE *f_, LIST(PTR(UNION)) x_, char *nm_, int d_)
827
{
808
{
828
    print_indent ( f_, d_ ) ;
809
    print_indent(f_, d_);
829
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
810
    (void)fprintf(f_, "%s = LIST {\n", nm_);
830
    while ( !IS_NULL_list ( x_ ) ) {
811
    while (!IS_NULL_list(x_)) {
831
	PTR ( UNION ) z_ ;
812
	PTR(UNION) z_;
832
	UN_CONS_ptr ( z_, x_, x_ ) ;
813
	UN_CONS_ptr(z_, x_, x_);
833
	PRINT_ptr_un ( f_, z_, "(ptr_un)", d_ + 1 ) ;
814
	PRINT_ptr_un(f_, z_, "(ptr_un)", d_ + 1);
834
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
815
	if (!print_list_expand && !IS_NULL_list(x_)) {
835
	    print_indent ( f_, d_ + 1 ) ;
816
	    print_indent(f_, d_ + 1);
836
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
817
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
837
	    break ;
818
	    break;
838
	}
819
	}
839
    }
820
    }
840
    print_indent ( f_, d_ ) ;
821
    print_indent(f_, d_);
841
    ( void ) fprintf ( f_, "}\n" ) ;
822
    (void)fprintf(f_, "}\n");
842
    return ;
823
    return;
843
}
824
}
844
 
825
 
845
#ifdef DEBUG
826
#ifdef DEBUG
846
 
827
 
847
void DEBUG_list_ptr_un
828
void
848
    PROTO_N ( ( x_ ) )
-
 
849
    PROTO_T ( LIST ( PTR ( UNION ) ) x_ )
829
DEBUG_list_ptr_un(LIST(PTR(UNION)) x_)
850
{
830
{
851
    PRINT_list_ptr_un ( stdout, x_, "list_ptr_un", 0 ) ;
831
    PRINT_list_ptr_un(stdout, x_, "list_ptr_un", 0);
852
    return ;
832
    return;
853
}
833
}
854
 
834
 
855
#endif
835
#endif
856
 
836
 
857
#endif
837
#endif
858
 
838
 
859
 
839
 
860
/* Printing routines for LIST ( PTR ( STRUCTURE ) ) */
840
/* Printing routines for LIST(PTR(STRUCTURE)) */
861
 
841
 
862
#ifndef PRINT_list_ptr_str
842
#ifndef PRINT_list_ptr_str
863
 
843
 
864
static void PRINT_list_ptr_str
844
static void
865
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
866
    PROTO_T ( FILE *f_ X LIST ( PTR ( STRUCTURE ) ) x_ X char *nm_ X int d_ )
845
PRINT_list_ptr_str(FILE *f_, LIST(PTR(STRUCTURE)) x_, char *nm_, int d_)
867
{
846
{
868
    print_indent ( f_, d_ ) ;
847
    print_indent(f_, d_);
869
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
848
    (void)fprintf(f_, "%s = LIST {\n", nm_);
870
    while ( !IS_NULL_list ( x_ ) ) {
849
    while (!IS_NULL_list(x_)) {
871
	PTR ( STRUCTURE ) z_ ;
850
	PTR(STRUCTURE) z_;
872
	UN_CONS_ptr ( z_, x_, x_ ) ;
851
	UN_CONS_ptr(z_, x_, x_);
873
	PRINT_ptr_str ( f_, z_, "(ptr_str)", d_ + 1 ) ;
852
	PRINT_ptr_str(f_, z_, "(ptr_str)", d_ + 1);
874
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
853
	if (!print_list_expand && !IS_NULL_list(x_)) {
875
	    print_indent ( f_, d_ + 1 ) ;
854
	    print_indent(f_, d_ + 1);
876
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
855
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
877
	    break ;
856
	    break;
878
	}
857
	}
879
    }
858
    }
880
    print_indent ( f_, d_ ) ;
859
    print_indent(f_, d_);
881
    ( void ) fprintf ( f_, "}\n" ) ;
860
    (void)fprintf(f_, "}\n");
882
    return ;
861
    return;
883
}
862
}
884
 
863
 
885
#ifdef DEBUG
864
#ifdef DEBUG
886
 
865
 
887
void DEBUG_list_ptr_str
866
void
888
    PROTO_N ( ( x_ ) )
-
 
889
    PROTO_T ( LIST ( PTR ( STRUCTURE ) ) x_ )
867
DEBUG_list_ptr_str(LIST(PTR(STRUCTURE)) x_)
890
{
868
{
891
    PRINT_list_ptr_str ( stdout, x_, "list_ptr_str", 0 ) ;
869
    PRINT_list_ptr_str(stdout, x_, "list_ptr_str", 0);
892
    return ;
870
    return;
893
}
871
}
894
 
872
 
895
#endif
873
#endif
896
 
874
 
897
#endif
875
#endif
898
 
876
 
899
 
877
 
900
/* Printing routines for LIST ( PTR ( ENUM ) ) */
878
/* Printing routines for LIST(PTR(ENUM)) */
901
 
879
 
902
#ifndef PRINT_list_ptr_en
880
#ifndef PRINT_list_ptr_en
903
 
881
 
904
static void PRINT_list_ptr_en
882
static void
905
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
906
    PROTO_T ( FILE *f_ X LIST ( PTR ( ENUM ) ) x_ X char *nm_ X int d_ )
883
PRINT_list_ptr_en(FILE *f_, LIST(PTR(ENUM)) x_, char *nm_, int d_)
907
{
884
{
908
    print_indent ( f_, d_ ) ;
885
    print_indent(f_, d_);
909
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
886
    (void)fprintf(f_, "%s = LIST {\n", nm_);
910
    while ( !IS_NULL_list ( x_ ) ) {
887
    while (!IS_NULL_list(x_)) {
911
	PTR ( ENUM ) z_ ;
888
	PTR(ENUM) z_;
912
	UN_CONS_ptr ( z_, x_, x_ ) ;
889
	UN_CONS_ptr(z_, x_, x_);
913
	PRINT_ptr_en ( f_, z_, "(ptr_en)", d_ + 1 ) ;
890
	PRINT_ptr_en(f_, z_, "(ptr_en)", d_ + 1);
914
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
891
	if (!print_list_expand && !IS_NULL_list(x_)) {
915
	    print_indent ( f_, d_ + 1 ) ;
892
	    print_indent(f_, d_ + 1);
916
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
893
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
917
	    break ;
894
	    break;
918
	}
895
	}
919
    }
896
    }
920
    print_indent ( f_, d_ ) ;
897
    print_indent(f_, d_);
921
    ( void ) fprintf ( f_, "}\n" ) ;
898
    (void)fprintf(f_, "}\n");
922
    return ;
899
    return;
923
}
900
}
924
 
901
 
925
#ifdef DEBUG
902
#ifdef DEBUG
926
 
903
 
927
void DEBUG_list_ptr_en
904
void
928
    PROTO_N ( ( x_ ) )
-
 
929
    PROTO_T ( LIST ( PTR ( ENUM ) ) x_ )
905
DEBUG_list_ptr_en(LIST(PTR(ENUM)) x_)
930
{
906
{
931
    PRINT_list_ptr_en ( stdout, x_, "list_ptr_en", 0 ) ;
907
    PRINT_list_ptr_en(stdout, x_, "list_ptr_en", 0);
932
    return ;
908
    return;
933
}
909
}
934
 
910
 
935
#endif
911
#endif
936
 
912
 
937
#endif
913
#endif
938
 
914
 
939
 
915
 
940
/* Printing routines for LIST ( PTR ( IDENTITY ) ) */
916
/* Printing routines for LIST(PTR(IDENTITY)) */
941
 
917
 
942
#ifndef PRINT_list_ptr_ident
918
#ifndef PRINT_list_ptr_ident
943
 
919
 
944
static void PRINT_list_ptr_ident
920
static void
945
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
946
    PROTO_T ( FILE *f_ X LIST ( PTR ( IDENTITY ) ) x_ X char *nm_ X int d_ )
921
PRINT_list_ptr_ident(FILE *f_, LIST(PTR(IDENTITY)) x_, char *nm_, int d_)
947
{
922
{
948
    print_indent ( f_, d_ ) ;
923
    print_indent(f_, d_);
949
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
924
    (void)fprintf(f_, "%s = LIST {\n", nm_);
950
    while ( !IS_NULL_list ( x_ ) ) {
925
    while (!IS_NULL_list(x_)) {
951
	PTR ( IDENTITY ) z_ ;
926
	PTR(IDENTITY) z_;
952
	UN_CONS_ptr ( z_, x_, x_ ) ;
927
	UN_CONS_ptr(z_, x_, x_);
953
	PRINT_ptr_ident ( f_, z_, "(ptr_ident)", d_ + 1 ) ;
928
	PRINT_ptr_ident(f_, z_, "(ptr_ident)", d_ + 1);
954
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
929
	if (!print_list_expand && !IS_NULL_list(x_)) {
955
	    print_indent ( f_, d_ + 1 ) ;
930
	    print_indent(f_, d_ + 1);
956
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
931
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
957
	    break ;
932
	    break;
958
	}
933
	}
959
    }
934
    }
960
    print_indent ( f_, d_ ) ;
935
    print_indent(f_, d_);
961
    ( void ) fprintf ( f_, "}\n" ) ;
936
    (void)fprintf(f_, "}\n");
962
    return ;
937
    return;
963
}
938
}
964
 
939
 
965
#ifdef DEBUG
940
#ifdef DEBUG
966
 
941
 
967
void DEBUG_list_ptr_ident
942
void
968
    PROTO_N ( ( x_ ) )
-
 
969
    PROTO_T ( LIST ( PTR ( IDENTITY ) ) x_ )
943
DEBUG_list_ptr_ident(LIST(PTR(IDENTITY)) x_)
970
{
944
{
971
    PRINT_list_ptr_ident ( stdout, x_, "list_ptr_ident", 0 ) ;
945
    PRINT_list_ptr_ident(stdout, x_, "list_ptr_ident", 0);
972
    return ;
946
    return;
973
}
947
}
974
 
948
 
975
#endif
949
#endif
976
 
950
 
977
#endif
951
#endif
978
 
952
 
979
 
953
 
980
/* Printing routines for LIST ( PTR ( PRIMITIVE ) ) */
954
/* Printing routines for LIST(PTR(PRIMITIVE)) */
981
 
955
 
982
#ifndef PRINT_list_ptr_prim
956
#ifndef PRINT_list_ptr_prim
983
 
957
 
984
static void PRINT_list_ptr_prim
958
static void
985
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
986
    PROTO_T ( FILE *f_ X LIST ( PTR ( PRIMITIVE ) ) x_ X char *nm_ X int d_ )
959
PRINT_list_ptr_prim(FILE *f_, LIST(PTR(PRIMITIVE)) x_, char *nm_, int d_)
987
{
960
{
988
    print_indent ( f_, d_ ) ;
961
    print_indent(f_, d_);
989
    ( void ) fprintf ( f_, "%s = LIST {\n", nm_ ) ;
962
    (void)fprintf(f_, "%s = LIST {\n", nm_);
990
    while ( !IS_NULL_list ( x_ ) ) {
963
    while (!IS_NULL_list(x_)) {
991
	PTR ( PRIMITIVE ) z_ ;
964
	PTR(PRIMITIVE) z_;
992
	UN_CONS_ptr ( z_, x_, x_ ) ;
965
	UN_CONS_ptr(z_, x_, x_);
993
	PRINT_ptr_prim ( f_, z_, "(ptr_prim)", d_ + 1 ) ;
966
	PRINT_ptr_prim(f_, z_, "(ptr_prim)", d_ + 1);
994
	if ( !print_list_expand && !IS_NULL_list ( x_ ) ) {
967
	if (!print_list_expand && !IS_NULL_list(x_)) {
995
	    print_indent ( f_, d_ + 1 ) ;
968
	    print_indent(f_, d_ + 1);
996
	    ( void ) fprintf ( f_, "(tail) = 0x%p ;\n", VOIDSTAR_list ( x_ ) ) ;
969
	    (void)fprintf(f_, "(tail) = 0x%p ;\n", VOIDSTAR_list(x_));
997
	    break ;
970
	    break;
998
	}
971
	}
999
    }
972
    }
1000
    print_indent ( f_, d_ ) ;
973
    print_indent(f_, d_);
1001
    ( void ) fprintf ( f_, "}\n" ) ;
974
    (void)fprintf(f_, "}\n");
1002
    return ;
975
    return;
1003
}
976
}
1004
 
977
 
1005
#ifdef DEBUG
978
#ifdef DEBUG
1006
 
979
 
1007
void DEBUG_list_ptr_prim
980
void
1008
    PROTO_N ( ( x_ ) )
-
 
1009
    PROTO_T ( LIST ( PTR ( PRIMITIVE ) ) x_ )
981
DEBUG_list_ptr_prim(LIST(PTR(PRIMITIVE)) x_)
1010
{
982
{
1011
    PRINT_list_ptr_prim ( stdout, x_, "list_ptr_prim", 0 ) ;
983
    PRINT_list_ptr_prim(stdout, x_, "list_ptr_prim", 0);
1012
    return ;
984
    return;
1013
}
985
}
1014
 
986
 
1015
#endif
987
#endif
1016
 
988
 
1017
#endif
989
#endif
1018
 
990
 
1019
 
991
 
1020
/* Printing routines for PTR ( UNION ) */
992
/* Printing routines for PTR(UNION) */
1021
 
993
 
1022
#ifndef PRINT_ptr_un
994
#ifndef PRINT_ptr_un
1023
 
995
 
1024
static void PRINT_ptr_un
996
static void
1025
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1026
    PROTO_T ( FILE *f_ X PTR ( UNION ) x_ X char *nm_ X int d_ )
997
PRINT_ptr_un(FILE *f_, PTR(UNION) x_, char *nm_, int d_)
1027
{
998
{
1028
    print_indent ( f_, d_ ) ;
999
    print_indent(f_, d_);
1029
    if ( IS_NULL_ptr ( x_ ) ) {
1000
    if (IS_NULL_ptr(x_)) {
1030
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1001
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1031
    } else if ( d_ < print_ptr_depth ) {
1002
    } else if (d_ < print_ptr_depth) {
1032
	UNION z_ ;
1003
	UNION z_;
1033
	DEREF_un ( x_, z_ ) ;
1004
	DEREF_un(x_, z_);
1034
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1005
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1035
	PRINT_un ( f_, z_, "(un)", d_ + 1 ) ;
1006
	PRINT_un(f_, z_, "(un)", d_ + 1);
1036
	print_indent ( f_, d_ ) ;
1007
	print_indent(f_, d_);
1037
	( void ) fprintf ( f_, "}\n" ) ;
1008
	(void)fprintf(f_, "}\n");
1038
    } else {
1009
    } else {
1039
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1010
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1040
    }
1011
    }
1041
    return ;
1012
    return;
1042
}
1013
}
1043
 
1014
 
1044
#ifdef DEBUG
1015
#ifdef DEBUG
1045
 
1016
 
1046
void DEBUG_ptr_un
1017
void
1047
    PROTO_N ( ( x_ ) )
-
 
1048
    PROTO_T ( PTR ( UNION ) x_ )
1018
DEBUG_ptr_un(PTR(UNION) x_)
1049
{
1019
{
1050
    PRINT_ptr_un ( stdout, x_, "ptr_un", 0 ) ;
1020
    PRINT_ptr_un(stdout, x_, "ptr_un", 0);
1051
    return ;
1021
    return;
1052
}
1022
}
1053
 
1023
 
1054
#endif
1024
#endif
1055
 
1025
 
1056
#endif
1026
#endif
Line 1058... Line 1028...
1058
 
1028
 
1059
/* Printing routines for UNION */
1029
/* Printing routines for UNION */
1060
 
1030
 
1061
#ifndef PRINT_un
1031
#ifndef PRINT_un
1062
 
1032
 
1063
static void PRINT_un
1033
static void
1064
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1065
    PROTO_T ( FILE *f_ X UNION x_ X char *nm_ X int d_ )
1034
PRINT_un(FILE *f_, UNION x_, char *nm_, int d_)
1066
{
1035
{
1067
    print_indent ( f_, d_ ) ;
1036
    print_indent(f_, d_);
1068
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1037
    (void)fprintf(f_, "%s = {\n", nm_);
1069
    PRINT_CLASS_ID_P ( f_, x_.id, "id", d_ + 1 ) ;
1038
    PRINT_CLASS_ID_P(f_, x_.id, "id", d_ + 1);
1070
    PRINT_UNION_P ( f_, x_.base, "base", d_ + 1 ) ;
1039
    PRINT_UNION_P(f_, x_.base, "base", d_ + 1);
1071
    PRINT_list_COMPONENT_P ( f_, x_.s_defn, "s_defn", d_ + 1 ) ;
1040
    PRINT_list_COMPONENT_P(f_, x_.s_defn, "s_defn", d_ + 1);
1072
    PRINT_list_FIELD_P ( f_, x_.u_defn, "u_defn", d_ + 1 ) ;
1041
    PRINT_list_FIELD_P(f_, x_.u_defn, "u_defn", d_ + 1);
1073
    PRINT_list_MAP_P ( f_, x_.map, "map", d_ + 1 ) ;
1042
    PRINT_list_MAP_P(f_, x_.map, "map", d_ + 1);
1074
    PRINT_int ( f_, x_.no_fields, "no_fields", d_ + 1 ) ;
1043
    PRINT_int(f_, x_.no_fields, "no_fields", d_ + 1);
1075
    print_indent ( f_, d_ ) ;
1044
    print_indent(f_, d_);
1076
    ( void ) fprintf ( f_, "}\n" ) ;
1045
    (void)fprintf(f_, "}\n");
1077
    return ;
1046
    return;
1078
}
1047
}
1079
 
1048
 
1080
#ifdef DEBUG
1049
#ifdef DEBUG
1081
 
1050
 
1082
void DEBUG_un
1051
void
1083
    PROTO_N ( ( x_ ) )
-
 
1084
    PROTO_T ( UNION *x_ )
1052
DEBUG_un(UNION *x_)
1085
{
1053
{
1086
    if ( x_ ) PRINT_un ( stdout, *x_, "un", 0 ) ;
1054
    if (x_)PRINT_un(stdout, *x_, "un", 0);
1087
    return ;
1055
    return;
1088
}
1056
}
1089
 
1057
 
1090
#endif
1058
#endif
1091
 
1059
 
1092
#endif
1060
#endif
1093
 
1061
 
1094
 
1062
 
1095
/* Printing routines for PTR ( PTR ( TYPE ) ) */
1063
/* Printing routines for PTR(PTR(TYPE)) */
1096
 
1064
 
1097
#ifndef PRINT_ptr_ptr_type
1065
#ifndef PRINT_ptr_ptr_type
1098
 
1066
 
1099
static void PRINT_ptr_ptr_type
1067
static void
1100
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1101
    PROTO_T ( FILE *f_ X PTR ( PTR ( TYPE ) ) x_ X char *nm_ X int d_ )
1068
PRINT_ptr_ptr_type(FILE *f_, PTR(PTR(TYPE)) x_, char *nm_, int d_)
1102
{
1069
{
1103
    print_indent ( f_, d_ ) ;
1070
    print_indent(f_, d_);
1104
    if ( IS_NULL_ptr ( x_ ) ) {
1071
    if (IS_NULL_ptr(x_)) {
1105
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1072
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1106
    } else if ( d_ < print_ptr_depth ) {
1073
    } else if (d_ < print_ptr_depth) {
1107
	PTR ( TYPE ) z_ ;
1074
	PTR(TYPE) z_;
1108
	z_ = DEREF_ptr ( x_ ) ;
1075
	z_ = DEREF_ptr(x_);
1109
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1076
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1110
	PRINT_ptr_type ( f_, z_, "(ptr_type)", d_ + 1 ) ;
1077
	PRINT_ptr_type(f_, z_, "(ptr_type)", d_ + 1);
1111
	print_indent ( f_, d_ ) ;
1078
	print_indent(f_, d_);
1112
	( void ) fprintf ( f_, "}\n" ) ;
1079
	(void)fprintf(f_, "}\n");
1113
    } else {
1080
    } else {
1114
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1081
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1115
    }
1082
    }
1116
    return ;
1083
    return;
1117
}
1084
}
1118
 
1085
 
1119
#ifdef DEBUG
1086
#ifdef DEBUG
1120
 
1087
 
1121
void DEBUG_ptr_ptr_type
1088
void
1122
    PROTO_N ( ( x_ ) )
-
 
1123
    PROTO_T ( PTR ( PTR ( TYPE ) ) x_ )
1089
DEBUG_ptr_ptr_type(PTR(PTR(TYPE)) x_)
1124
{
1090
{
1125
    PRINT_ptr_ptr_type ( stdout, x_, "ptr_ptr_type", 0 ) ;
1091
    PRINT_ptr_ptr_type(stdout, x_, "ptr_ptr_type", 0);
1126
    return ;
1092
    return;
1127
}
1093
}
1128
 
1094
 
1129
#endif
1095
#endif
1130
 
1096
 
1131
#endif
1097
#endif
1132
 
1098
 
1133
 
1099
 
1134
/* Printing routines for PTR ( TYPE ) */
1100
/* Printing routines for PTR(TYPE) */
1135
 
1101
 
1136
#ifndef PRINT_ptr_type
1102
#ifndef PRINT_ptr_type
1137
 
1103
 
1138
static void PRINT_ptr_type
1104
static void
1139
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1140
    PROTO_T ( FILE *f_ X PTR ( TYPE ) x_ X char *nm_ X int d_ )
1105
PRINT_ptr_type(FILE *f_, PTR(TYPE) x_, char *nm_, int d_)
1141
{
1106
{
1142
    print_indent ( f_, d_ ) ;
1107
    print_indent(f_, d_);
1143
    if ( IS_NULL_ptr ( x_ ) ) {
1108
    if (IS_NULL_ptr(x_)) {
1144
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1109
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1145
    } else if ( d_ < print_ptr_depth ) {
1110
    } else if (d_ < print_ptr_depth) {
1146
	TYPE z_ ;
1111
	TYPE z_;
1147
	z_ = DEREF_type ( x_ ) ;
1112
	z_ = DEREF_type(x_);
1148
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1113
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1149
	PRINT_type ( f_, z_, "(type)", d_ + 1 ) ;
1114
	PRINT_type(f_, z_, "(type)", d_ + 1);
1150
	print_indent ( f_, d_ ) ;
1115
	print_indent(f_, d_);
1151
	( void ) fprintf ( f_, "}\n" ) ;
1116
	(void)fprintf(f_, "}\n");
1152
    } else {
1117
    } else {
1153
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1118
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1154
    }
1119
    }
1155
    return ;
1120
    return;
1156
}
1121
}
1157
 
1122
 
1158
#ifdef DEBUG
1123
#ifdef DEBUG
1159
 
1124
 
1160
void DEBUG_ptr_type
1125
void
1161
    PROTO_N ( ( x_ ) )
-
 
1162
    PROTO_T ( PTR ( TYPE ) x_ )
1126
DEBUG_ptr_type(PTR(TYPE) x_)
1163
{
1127
{
1164
    PRINT_ptr_type ( stdout, x_, "ptr_type", 0 ) ;
1128
    PRINT_ptr_type(stdout, x_, "ptr_type", 0);
1165
    return ;
1129
    return;
1166
}
1130
}
1167
 
1131
 
1168
#endif
1132
#endif
1169
 
1133
 
1170
#endif
1134
#endif
Line 1172... Line 1136...
1172
 
1136
 
1173
/* Printing routines for TYPE */
1137
/* Printing routines for TYPE */
1174
 
1138
 
1175
#ifndef PRINT_type
1139
#ifndef PRINT_type
1176
 
1140
 
1177
static void PRINT_type
1141
static void
1178
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1179
    PROTO_T ( FILE *f_ X TYPE x_ X char *nm_ X int d_ )
1142
PRINT_type(FILE *f_, TYPE x_, char *nm_, int d_)
1180
{
1143
{
1181
    print_indent ( f_, d_ ) ;
1144
    print_indent(f_, d_);
1182
    if ( IS_NULL_type ( x_ ) ) {
1145
    if (IS_NULL_type(x_)) {
1183
	( void ) fprintf ( f_, "%s = NULL_type ;\n", nm_ ) ;
1146
	(void)fprintf(f_, "%s = NULL_type ;\n", nm_);
1184
    } else {
1147
    } else {
1185
	switch ( TAG_type ( x_ ) ) {
1148
	switch (TAG_type(x_)) {
1186
	    case type_primitive_tag : {
1149
	    case type_primitive_tag: {
1187
		unsigned alias_ = GET_ALIAS_type_primitive ( x_ ) ;
1150
		unsigned alias_ = GET_ALIAS_type_primitive(x_);
1188
		if ( alias_ ) {
1151
		if (alias_) {
1189
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1152
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1190
		    break ;
1153
		    break;
1191
		}
1154
		}
1192
		alias_ = ++crt_calculus_alias ;
1155
		alias_ = ++crt_calculus_alias ;
1193
		SET_ALIAS_type_primitive ( x_, alias_ ) ;
1156
		SET_ALIAS_type_primitive(x_, alias_);
1194
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1157
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1195
		print_indent ( f_, d_ + 1 ) ;
1158
		print_indent(f_, d_ + 1);
1196
		( void ) fprintf ( f_, "(tag) = primitive ;\n" ) ;
1159
		(void)fprintf(f_, "(tag) = primitive ;\n");
1197
		{
1160
		{
1198
		    zero_int z_ ;
1161
		    zero_int z_;
1199
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1162
		    z_ = DEREF_int(type_size(x_));
1200
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1163
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1201
		}
1164
		}
1202
		{
1165
		{
1203
		    PRIMITIVE_P z_ ;
1166
		    PRIMITIVE_P z_;
1204
		    z_ = DEREF_ptr ( type_primitive_prim ( x_ ) ) ;
1167
		    z_ = DEREF_ptr(type_primitive_prim(x_));
1205
		    PRINT_PRIMITIVE_P ( f_, z_, "prim", d_ + 1 ) ;
1168
		    PRINT_PRIMITIVE_P(f_, z_, "prim", d_ + 1);
1206
		}
1169
		}
1207
		print_indent ( f_, d_ ) ;
1170
		print_indent(f_, d_);
1208
		( void ) fprintf ( f_, "}\n" ) ;
1171
		(void)fprintf(f_, "}\n");
1209
		break ;
1172
		break;
1210
	    }
1173
	    }
1211
	    case type_ident_tag : {
1174
	    case type_ident_tag: {
1212
		unsigned alias_ = GET_ALIAS_type_ident ( x_ ) ;
1175
		unsigned alias_ = GET_ALIAS_type_ident(x_);
1213
		if ( alias_ ) {
1176
		if (alias_) {
1214
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1177
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1215
		    break ;
1178
		    break;
1216
		}
1179
		}
1217
		alias_ = ++crt_calculus_alias ;
1180
		alias_ = ++crt_calculus_alias ;
1218
		SET_ALIAS_type_ident ( x_, alias_ ) ;
1181
		SET_ALIAS_type_ident(x_, alias_);
1219
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1182
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1220
		print_indent ( f_, d_ + 1 ) ;
1183
		print_indent(f_, d_ + 1);
1221
		( void ) fprintf ( f_, "(tag) = ident ;\n" ) ;
1184
		(void)fprintf(f_, "(tag) = ident ;\n");
1222
		{
1185
		{
1223
		    zero_int z_ ;
1186
		    zero_int z_;
1224
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1187
		    z_ = DEREF_int(type_size(x_));
1225
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1188
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1226
		}
1189
		}
1227
		{
1190
		{
1228
		    IDENTITY_P z_ ;
1191
		    IDENTITY_P z_;
1229
		    z_ = DEREF_ptr ( type_ident_id ( x_ ) ) ;
1192
		    z_ = DEREF_ptr(type_ident_id(x_));
1230
		    PRINT_IDENTITY_P ( f_, z_, "id", d_ + 1 ) ;
1193
		    PRINT_IDENTITY_P(f_, z_, "id", d_ + 1);
1231
		}
1194
		}
1232
		print_indent ( f_, d_ ) ;
1195
		print_indent(f_, d_);
1233
		( void ) fprintf ( f_, "}\n" ) ;
1196
		(void)fprintf(f_, "}\n");
1234
		break ;
1197
		break;
1235
	    }
1198
	    }
1236
	    case type_enumeration_tag : {
1199
	    case type_enumeration_tag: {
1237
		unsigned alias_ = GET_ALIAS_type_enumeration ( x_ ) ;
1200
		unsigned alias_ = GET_ALIAS_type_enumeration(x_);
1238
		if ( alias_ ) {
1201
		if (alias_) {
1239
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1202
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1240
		    break ;
1203
		    break;
1241
		}
1204
		}
1242
		alias_ = ++crt_calculus_alias ;
1205
		alias_ = ++crt_calculus_alias ;
1243
		SET_ALIAS_type_enumeration ( x_, alias_ ) ;
1206
		SET_ALIAS_type_enumeration(x_, alias_);
1244
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1207
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1245
		print_indent ( f_, d_ + 1 ) ;
1208
		print_indent(f_, d_ + 1);
1246
		( void ) fprintf ( f_, "(tag) = enumeration ;\n" ) ;
1209
		(void)fprintf(f_, "(tag) = enumeration ;\n");
1247
		{
1210
		{
1248
		    zero_int z_ ;
1211
		    zero_int z_;
1249
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1212
		    z_ = DEREF_int(type_size(x_));
1250
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1213
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1251
		}
1214
		}
1252
		{
1215
		{
1253
		    ENUM_P z_ ;
1216
		    ENUM_P z_;
1254
		    z_ = DEREF_ptr ( type_enumeration_en ( x_ ) ) ;
1217
		    z_ = DEREF_ptr(type_enumeration_en(x_));
1255
		    PRINT_ENUM_P ( f_, z_, "en", d_ + 1 ) ;
1218
		    PRINT_ENUM_P(f_, z_, "en", d_ + 1);
1256
		}
1219
		}
1257
		print_indent ( f_, d_ ) ;
1220
		print_indent(f_, d_);
1258
		( void ) fprintf ( f_, "}\n" ) ;
1221
		(void)fprintf(f_, "}\n");
1259
		break ;
1222
		break;
1260
	    }
1223
	    }
1261
	    case type_structure_tag : {
1224
	    case type_structure_tag: {
1262
		unsigned alias_ = GET_ALIAS_type_structure ( x_ ) ;
1225
		unsigned alias_ = GET_ALIAS_type_structure(x_);
1263
		if ( alias_ ) {
1226
		if (alias_) {
1264
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1227
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1265
		    break ;
1228
		    break;
1266
		}
1229
		}
1267
		alias_ = ++crt_calculus_alias ;
1230
		alias_ = ++crt_calculus_alias ;
1268
		SET_ALIAS_type_structure ( x_, alias_ ) ;
1231
		SET_ALIAS_type_structure(x_, alias_);
1269
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1232
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1270
		print_indent ( f_, d_ + 1 ) ;
1233
		print_indent(f_, d_ + 1);
1271
		( void ) fprintf ( f_, "(tag) = structure ;\n" ) ;
1234
		(void)fprintf(f_, "(tag) = structure ;\n");
1272
		{
1235
		{
1273
		    zero_int z_ ;
1236
		    zero_int z_;
1274
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1237
		    z_ = DEREF_int(type_size(x_));
1275
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1238
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1276
		}
1239
		}
1277
		{
1240
		{
1278
		    STRUCTURE_P z_ ;
1241
		    STRUCTURE_P z_;
1279
		    z_ = DEREF_ptr ( type_structure_struc ( x_ ) ) ;
1242
		    z_ = DEREF_ptr(type_structure_struc(x_));
1280
		    PRINT_STRUCTURE_P ( f_, z_, "struc", d_ + 1 ) ;
1243
		    PRINT_STRUCTURE_P(f_, z_, "struc", d_ + 1);
1281
		}
1244
		}
1282
		print_indent ( f_, d_ ) ;
1245
		print_indent(f_, d_);
1283
		( void ) fprintf ( f_, "}\n" ) ;
1246
		(void)fprintf(f_, "}\n");
1284
		break ;
1247
		break;
1285
	    }
1248
	    }
1286
	    case type_onion_tag : {
1249
	    case type_onion_tag: {
1287
		unsigned alias_ = GET_ALIAS_type_onion ( x_ ) ;
1250
		unsigned alias_ = GET_ALIAS_type_onion(x_);
1288
		if ( alias_ ) {
1251
		if (alias_) {
1289
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1252
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1290
		    break ;
1253
		    break;
1291
		}
1254
		}
1292
		alias_ = ++crt_calculus_alias ;
1255
		alias_ = ++crt_calculus_alias ;
1293
		SET_ALIAS_type_onion ( x_, alias_ ) ;
1256
		SET_ALIAS_type_onion(x_, alias_);
1294
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1257
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1295
		print_indent ( f_, d_ + 1 ) ;
1258
		print_indent(f_, d_ + 1);
1296
		( void ) fprintf ( f_, "(tag) = onion ;\n" ) ;
1259
		(void)fprintf(f_, "(tag) = onion ;\n");
1297
		{
1260
		{
1298
		    zero_int z_ ;
1261
		    zero_int z_;
1299
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1262
		    z_ = DEREF_int(type_size(x_));
1300
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1263
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1301
		}
1264
		}
1302
		{
1265
		{
1303
		    UNION_P z_ ;
1266
		    UNION_P z_;
1304
		    z_ = DEREF_ptr ( type_onion_un ( x_ ) ) ;
1267
		    z_ = DEREF_ptr(type_onion_un(x_));
1305
		    PRINT_UNION_P ( f_, z_, "un", d_ + 1 ) ;
1268
		    PRINT_UNION_P(f_, z_, "un", d_ + 1);
1306
		}
1269
		}
1307
		print_indent ( f_, d_ ) ;
1270
		print_indent(f_, d_);
1308
		( void ) fprintf ( f_, "}\n" ) ;
1271
		(void)fprintf(f_, "}\n");
1309
		break ;
1272
		break;
1310
	    }
1273
	    }
1311
	    case type_ptr_tag : {
1274
	    case type_ptr_tag: {
1312
		unsigned alias_ = GET_ALIAS_type_ptr ( x_ ) ;
1275
		unsigned alias_ = GET_ALIAS_type_ptr(x_);
1313
		if ( alias_ ) {
1276
		if (alias_) {
1314
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1277
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1315
		    break ;
1278
		    break;
1316
		}
1279
		}
1317
		alias_ = ++crt_calculus_alias ;
1280
		alias_ = ++crt_calculus_alias ;
1318
		SET_ALIAS_type_ptr ( x_, alias_ ) ;
1281
		SET_ALIAS_type_ptr(x_, alias_);
1319
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1282
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1320
		print_indent ( f_, d_ + 1 ) ;
1283
		print_indent(f_, d_ + 1);
1321
		( void ) fprintf ( f_, "(tag) = ptr ;\n" ) ;
1284
		(void)fprintf(f_, "(tag) = ptr ;\n");
1322
		{
1285
		{
1323
		    zero_int z_ ;
1286
		    zero_int z_;
1324
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1287
		    z_ = DEREF_int(type_size(x_));
1325
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1288
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1326
		}
1289
		}
1327
		{
1290
		{
1328
		    TYPE_P z_ ;
1291
		    TYPE_P z_;
1329
		    z_ = DEREF_ptr ( type_ptr_sub ( x_ ) ) ;
1292
		    z_ = DEREF_ptr(type_ptr_sub(x_));
1330
		    PRINT_TYPE_P ( f_, z_, "sub", d_ + 1 ) ;
1293
		    PRINT_TYPE_P(f_, z_, "sub", d_ + 1);
1331
		}
1294
		}
1332
		print_indent ( f_, d_ ) ;
1295
		print_indent(f_, d_);
1333
		( void ) fprintf ( f_, "}\n" ) ;
1296
		(void)fprintf(f_, "}\n");
1334
		break ;
1297
		break;
1335
	    }
1298
	    }
1336
	    case type_list_tag : {
1299
	    case type_list_tag: {
1337
		unsigned alias_ = GET_ALIAS_type_list ( x_ ) ;
1300
		unsigned alias_ = GET_ALIAS_type_list(x_);
1338
		if ( alias_ ) {
1301
		if (alias_) {
1339
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1302
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1340
		    break ;
1303
		    break;
1341
		}
1304
		}
1342
		alias_ = ++crt_calculus_alias ;
1305
		alias_ = ++crt_calculus_alias ;
1343
		SET_ALIAS_type_list ( x_, alias_ ) ;
1306
		SET_ALIAS_type_list(x_, alias_);
1344
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1307
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1345
		print_indent ( f_, d_ + 1 ) ;
1308
		print_indent(f_, d_ + 1);
1346
		( void ) fprintf ( f_, "(tag) = list ;\n" ) ;
1309
		(void)fprintf(f_, "(tag) = list ;\n");
1347
		{
1310
		{
1348
		    zero_int z_ ;
1311
		    zero_int z_;
1349
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1312
		    z_ = DEREF_int(type_size(x_));
1350
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1313
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1351
		}
1314
		}
1352
		{
1315
		{
1353
		    TYPE_P z_ ;
1316
		    TYPE_P z_;
1354
		    z_ = DEREF_ptr ( type_list_sub ( x_ ) ) ;
1317
		    z_ = DEREF_ptr(type_list_sub(x_));
1355
		    PRINT_TYPE_P ( f_, z_, "sub", d_ + 1 ) ;
1318
		    PRINT_TYPE_P(f_, z_, "sub", d_ + 1);
1356
		}
1319
		}
1357
		print_indent ( f_, d_ ) ;
1320
		print_indent(f_, d_);
1358
		( void ) fprintf ( f_, "}\n" ) ;
1321
		(void)fprintf(f_, "}\n");
1359
		break ;
1322
		break;
1360
	    }
1323
	    }
1361
	    case type_stack_tag : {
1324
	    case type_stack_tag: {
1362
		unsigned alias_ = GET_ALIAS_type_stack ( x_ ) ;
1325
		unsigned alias_ = GET_ALIAS_type_stack(x_);
1363
		if ( alias_ ) {
1326
		if (alias_) {
1364
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1327
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1365
		    break ;
1328
		    break;
1366
		}
1329
		}
1367
		alias_ = ++crt_calculus_alias ;
1330
		alias_ = ++crt_calculus_alias ;
1368
		SET_ALIAS_type_stack ( x_, alias_ ) ;
1331
		SET_ALIAS_type_stack(x_, alias_);
1369
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1332
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1370
		print_indent ( f_, d_ + 1 ) ;
1333
		print_indent(f_, d_ + 1);
1371
		( void ) fprintf ( f_, "(tag) = stack ;\n" ) ;
1334
		(void)fprintf(f_, "(tag) = stack ;\n");
1372
		{
1335
		{
1373
		    zero_int z_ ;
1336
		    zero_int z_;
1374
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1337
		    z_ = DEREF_int(type_size(x_));
1375
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1338
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1376
		}
1339
		}
1377
		{
1340
		{
1378
		    TYPE_P z_ ;
1341
		    TYPE_P z_;
1379
		    z_ = DEREF_ptr ( type_stack_sub ( x_ ) ) ;
1342
		    z_ = DEREF_ptr(type_stack_sub(x_));
1380
		    PRINT_TYPE_P ( f_, z_, "sub", d_ + 1 ) ;
1343
		    PRINT_TYPE_P(f_, z_, "sub", d_ + 1);
1381
		}
1344
		}
1382
		print_indent ( f_, d_ ) ;
1345
		print_indent(f_, d_);
1383
		( void ) fprintf ( f_, "}\n" ) ;
1346
		(void)fprintf(f_, "}\n");
1384
		break ;
1347
		break;
1385
	    }
1348
	    }
1386
	    case type_vec_tag : {
1349
	    case type_vec_tag: {
1387
		unsigned alias_ = GET_ALIAS_type_vec ( x_ ) ;
1350
		unsigned alias_ = GET_ALIAS_type_vec(x_);
1388
		if ( alias_ ) {
1351
		if (alias_) {
1389
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1352
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1390
		    break ;
1353
		    break;
1391
		}
1354
		}
1392
		alias_ = ++crt_calculus_alias ;
1355
		alias_ = ++crt_calculus_alias ;
1393
		SET_ALIAS_type_vec ( x_, alias_ ) ;
1356
		SET_ALIAS_type_vec(x_, alias_);
1394
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1357
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1395
		print_indent ( f_, d_ + 1 ) ;
1358
		print_indent(f_, d_ + 1);
1396
		( void ) fprintf ( f_, "(tag) = vec ;\n" ) ;
1359
		(void)fprintf(f_, "(tag) = vec ;\n");
1397
		{
1360
		{
1398
		    zero_int z_ ;
1361
		    zero_int z_;
1399
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1362
		    z_ = DEREF_int(type_size(x_));
1400
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1363
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1401
		}
1364
		}
1402
		{
1365
		{
1403
		    TYPE_P z_ ;
1366
		    TYPE_P z_;
1404
		    z_ = DEREF_ptr ( type_vec_sub ( x_ ) ) ;
1367
		    z_ = DEREF_ptr(type_vec_sub(x_));
1405
		    PRINT_TYPE_P ( f_, z_, "sub", d_ + 1 ) ;
1368
		    PRINT_TYPE_P(f_, z_, "sub", d_ + 1);
1406
		}
1369
		}
1407
		print_indent ( f_, d_ ) ;
1370
		print_indent(f_, d_);
1408
		( void ) fprintf ( f_, "}\n" ) ;
1371
		(void)fprintf(f_, "}\n");
1409
		break ;
1372
		break;
1410
	    }
1373
	    }
1411
	    case type_vec_ptr_tag : {
1374
	    case type_vec_ptr_tag: {
1412
		unsigned alias_ = GET_ALIAS_type_vec_ptr ( x_ ) ;
1375
		unsigned alias_ = GET_ALIAS_type_vec_ptr(x_);
1413
		if ( alias_ ) {
1376
		if (alias_) {
1414
		    ( void ) fprintf ( f_, "%s = [%u] ;\n", nm_, alias_ ) ;
1377
		    (void)fprintf(f_, "%s = [%u] ;\n", nm_, alias_);
1415
		    break ;
1378
		    break;
1416
		}
1379
		}
1417
		alias_ = ++crt_calculus_alias ;
1380
		alias_ = ++crt_calculus_alias ;
1418
		SET_ALIAS_type_vec_ptr ( x_, alias_ ) ;
1381
		SET_ALIAS_type_vec_ptr(x_, alias_);
1419
		( void ) fprintf ( f_, "%s = [%u] = {\n", nm_, alias_ ) ;
1382
		(void)fprintf(f_, "%s = [%u] = {\n", nm_, alias_);
1420
		print_indent ( f_, d_ + 1 ) ;
1383
		print_indent(f_, d_ + 1);
1421
		( void ) fprintf ( f_, "(tag) = vec_ptr ;\n" ) ;
1384
		(void)fprintf(f_, "(tag) = vec_ptr ;\n");
1422
		{
1385
		{
1423
		    zero_int z_ ;
1386
		    zero_int z_;
1424
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1387
		    z_ = DEREF_int(type_size(x_));
1425
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1388
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1426
		}
1389
		}
1427
		{
1390
		{
1428
		    TYPE_P z_ ;
1391
		    TYPE_P z_;
1429
		    z_ = DEREF_ptr ( type_vec_ptr_sub ( x_ ) ) ;
1392
		    z_ = DEREF_ptr(type_vec_ptr_sub(x_));
1430
		    PRINT_TYPE_P ( f_, z_, "sub", d_ + 1 ) ;
1393
		    PRINT_TYPE_P(f_, z_, "sub", d_ + 1);
1431
		}
1394
		}
1432
		print_indent ( f_, d_ ) ;
1395
		print_indent(f_, d_);
1433
		( void ) fprintf ( f_, "}\n" ) ;
1396
		(void)fprintf(f_, "}\n");
1434
		break ;
1397
		break;
1435
	    }
1398
	    }
1436
	    case type_quote_tag : {
1399
	    case type_quote_tag: {
1437
		( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1400
		(void)fprintf(f_, "%s = {\n", nm_);
1438
		print_indent ( f_, d_ + 1 ) ;
1401
		print_indent(f_, d_ + 1);
1439
		( void ) fprintf ( f_, "(tag) = quote ;\n" ) ;
1402
		(void)fprintf(f_, "(tag) = quote ;\n");
1440
		{
1403
		{
1441
		    zero_int z_ ;
1404
		    zero_int z_;
1442
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1405
		    z_ = DEREF_int(type_size(x_));
1443
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1406
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1444
		}
1407
		}
1445
		{
1408
		{
1446
		    string z_ ;
1409
		    string z_;
1447
		    z_ = DEREF_string ( type_quote_defn ( x_ ) ) ;
1410
		    z_ = DEREF_string(type_quote_defn(x_));
1448
		    PRINT_string ( f_, z_, "defn", d_ + 1 ) ;
1411
		    PRINT_string(f_, z_, "defn", d_ + 1);
1449
		}
1412
		}
1450
		print_indent ( f_, d_ ) ;
1413
		print_indent(f_, d_);
1451
		( void ) fprintf ( f_, "}\n" ) ;
1414
		(void)fprintf(f_, "}\n");
1452
		break ;
1415
		break;
1453
	    }
1416
	    }
1454
	    case type_undef_tag : {
1417
	    case type_undef_tag: {
1455
		( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1418
		(void)fprintf(f_, "%s = {\n", nm_);
1456
		print_indent ( f_, d_ + 1 ) ;
1419
		print_indent(f_, d_ + 1);
1457
		( void ) fprintf ( f_, "(tag) = undef ;\n" ) ;
1420
		(void)fprintf(f_, "(tag) = undef ;\n");
1458
		{
1421
		{
1459
		    zero_int z_ ;
1422
		    zero_int z_;
1460
		    z_ = DEREF_int ( type_size ( x_ ) ) ;
1423
		    z_ = DEREF_int(type_size(x_));
1461
		    PRINT_zero_int ( f_, z_, "size", d_ + 1 ) ;
1424
		    PRINT_zero_int(f_, z_, "size", d_ + 1);
1462
		}
1425
		}
1463
		{
1426
		{
1464
		    string z_ ;
1427
		    string z_;
1465
		    z_ = DEREF_string ( type_undef_name ( x_ ) ) ;
1428
		    z_ = DEREF_string(type_undef_name(x_));
1466
		    PRINT_string ( f_, z_, "name", d_ + 1 ) ;
1429
		    PRINT_string(f_, z_, "name", d_ + 1);
1467
		}
1430
		}
1468
		print_indent ( f_, d_ ) ;
1431
		print_indent(f_, d_);
1469
		( void ) fprintf ( f_, "}\n" ) ;
1432
		(void)fprintf(f_, "}\n");
1470
		break ;
1433
		break;
1471
	    }
1434
	    }
1472
	    default : {
1435
	    default : {
1473
		( void ) fprintf ( f_, "%s = ERROR!\n", nm_ ) ;
1436
		(void)fprintf(f_, "%s = ERROR!\n", nm_);
1474
		break ;
1437
		break;
1475
	    }
1438
	    }
1476
	}
1439
	}
1477
    }
1440
    }
1478
    return ;
1441
    return;
1479
}
1442
}
1480
 
1443
 
1481
#ifdef DEBUG
1444
#ifdef DEBUG
1482
 
1445
 
1483
void DEBUG_type
1446
void
1484
    PROTO_N ( ( x_ ) )
-
 
1485
    PROTO_T ( TYPE x_ )
1447
DEBUG_type(TYPE x_)
1486
{
1448
{
1487
    PRINT_type ( stdout, x_, "type", 0 ) ;
1449
    PRINT_type(stdout, x_, "type", 0);
1488
    return ;
1450
    return;
1489
}
1451
}
1490
 
1452
 
1491
#endif
1453
#endif
1492
 
1454
 
1493
#endif
1455
#endif
1494
 
1456
 
1495
 
1457
 
1496
/* Printing routines for PTR ( STRUCTURE ) */
1458
/* Printing routines for PTR(STRUCTURE) */
1497
 
1459
 
1498
#ifndef PRINT_ptr_str
1460
#ifndef PRINT_ptr_str
1499
 
1461
 
1500
static void PRINT_ptr_str
1462
static void
1501
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1502
    PROTO_T ( FILE *f_ X PTR ( STRUCTURE ) x_ X char *nm_ X int d_ )
1463
PRINT_ptr_str(FILE *f_, PTR(STRUCTURE) x_, char *nm_, int d_)
1503
{
1464
{
1504
    print_indent ( f_, d_ ) ;
1465
    print_indent(f_, d_);
1505
    if ( IS_NULL_ptr ( x_ ) ) {
1466
    if (IS_NULL_ptr(x_)) {
1506
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1467
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1507
    } else if ( d_ < print_ptr_depth ) {
1468
    } else if (d_ < print_ptr_depth) {
1508
	STRUCTURE z_ ;
1469
	STRUCTURE z_;
1509
	DEREF_str ( x_, z_ ) ;
1470
	DEREF_str(x_, z_);
1510
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1471
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1511
	PRINT_str ( f_, z_, "(str)", d_ + 1 ) ;
1472
	PRINT_str(f_, z_, "(str)", d_ + 1);
1512
	print_indent ( f_, d_ ) ;
1473
	print_indent(f_, d_);
1513
	( void ) fprintf ( f_, "}\n" ) ;
1474
	(void)fprintf(f_, "}\n");
1514
    } else {
1475
    } else {
1515
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1476
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1516
    }
1477
    }
1517
    return ;
1478
    return;
1518
}
1479
}
1519
 
1480
 
1520
#ifdef DEBUG
1481
#ifdef DEBUG
1521
 
1482
 
1522
void DEBUG_ptr_str
1483
void
1523
    PROTO_N ( ( x_ ) )
-
 
1524
    PROTO_T ( PTR ( STRUCTURE ) x_ )
1484
DEBUG_ptr_str(PTR(STRUCTURE) x_)
1525
{
1485
{
1526
    PRINT_ptr_str ( stdout, x_, "ptr_str", 0 ) ;
1486
    PRINT_ptr_str(stdout, x_, "ptr_str", 0);
1527
    return ;
1487
    return;
1528
}
1488
}
1529
 
1489
 
1530
#endif
1490
#endif
1531
 
1491
 
1532
#endif
1492
#endif
Line 1534... Line 1494...
1534
 
1494
 
1535
/* Printing routines for STRUCTURE */
1495
/* Printing routines for STRUCTURE */
1536
 
1496
 
1537
#ifndef PRINT_str
1497
#ifndef PRINT_str
1538
 
1498
 
1539
static void PRINT_str
1499
static void
1540
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1541
    PROTO_T ( FILE *f_ X STRUCTURE x_ X char *nm_ X int d_ )
1500
PRINT_str(FILE *f_, STRUCTURE x_, char *nm_, int d_)
1542
{
1501
{
1543
    print_indent ( f_, d_ ) ;
1502
    print_indent(f_, d_);
1544
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1503
    (void)fprintf(f_, "%s = {\n", nm_);
1545
    PRINT_CLASS_ID_P ( f_, x_.id, "id", d_ + 1 ) ;
1504
    PRINT_CLASS_ID_P(f_, x_.id, "id", d_ + 1);
1546
    PRINT_STRUCTURE_P ( f_, x_.base, "base", d_ + 1 ) ;
1505
    PRINT_STRUCTURE_P(f_, x_.base, "base", d_ + 1);
1547
    PRINT_list_COMPONENT_P ( f_, x_.defn, "defn", d_ + 1 ) ;
1506
    PRINT_list_COMPONENT_P(f_, x_.defn, "defn", d_ + 1);
1548
    PRINT_zero_int ( f_, x_.output, "output", d_ + 1 ) ;
1507
    PRINT_zero_int(f_, x_.output, "output", d_ + 1);
1549
    print_indent ( f_, d_ ) ;
1508
    print_indent(f_, d_);
1550
    ( void ) fprintf ( f_, "}\n" ) ;
1509
    (void)fprintf(f_, "}\n");
1551
    return ;
1510
    return;
1552
}
1511
}
1553
 
1512
 
1554
#ifdef DEBUG
1513
#ifdef DEBUG
1555
 
1514
 
1556
void DEBUG_str
1515
void
1557
    PROTO_N ( ( x_ ) )
-
 
1558
    PROTO_T ( STRUCTURE *x_ )
1516
DEBUG_str(STRUCTURE *x_)
1559
{
1517
{
1560
    if ( x_ ) PRINT_str ( stdout, *x_, "str", 0 ) ;
1518
    if (x_)PRINT_str(stdout, *x_, "str", 0);
1561
    return ;
1519
    return;
1562
}
1520
}
1563
 
1521
 
1564
#endif
1522
#endif
1565
 
1523
 
1566
#endif
1524
#endif
1567
 
1525
 
1568
 
1526
 
1569
/* Printing routines for PTR ( PRIMITIVE ) */
1527
/* Printing routines for PTR(PRIMITIVE) */
1570
 
1528
 
1571
#ifndef PRINT_ptr_prim
1529
#ifndef PRINT_ptr_prim
1572
 
1530
 
1573
static void PRINT_ptr_prim
1531
static void
1574
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1575
    PROTO_T ( FILE *f_ X PTR ( PRIMITIVE ) x_ X char *nm_ X int d_ )
1532
PRINT_ptr_prim(FILE *f_, PTR(PRIMITIVE) x_, char *nm_, int d_)
1576
{
1533
{
1577
    print_indent ( f_, d_ ) ;
1534
    print_indent(f_, d_);
1578
    if ( IS_NULL_ptr ( x_ ) ) {
1535
    if (IS_NULL_ptr(x_)) {
1579
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1536
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1580
    } else if ( d_ < print_ptr_depth ) {
1537
    } else if (d_ < print_ptr_depth) {
1581
	PRIMITIVE z_ ;
1538
	PRIMITIVE z_;
1582
	DEREF_prim ( x_, z_ ) ;
1539
	DEREF_prim(x_, z_);
1583
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1540
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1584
	PRINT_prim ( f_, z_, "(prim)", d_ + 1 ) ;
1541
	PRINT_prim(f_, z_, "(prim)", d_ + 1);
1585
	print_indent ( f_, d_ ) ;
1542
	print_indent(f_, d_);
1586
	( void ) fprintf ( f_, "}\n" ) ;
1543
	(void)fprintf(f_, "}\n");
1587
    } else {
1544
    } else {
1588
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1545
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1589
    }
1546
    }
1590
    return ;
1547
    return;
1591
}
1548
}
1592
 
1549
 
1593
#ifdef DEBUG
1550
#ifdef DEBUG
1594
 
1551
 
1595
void DEBUG_ptr_prim
1552
void
1596
    PROTO_N ( ( x_ ) )
-
 
1597
    PROTO_T ( PTR ( PRIMITIVE ) x_ )
1553
DEBUG_ptr_prim(PTR(PRIMITIVE) x_)
1598
{
1554
{
1599
    PRINT_ptr_prim ( stdout, x_, "ptr_prim", 0 ) ;
1555
    PRINT_ptr_prim(stdout, x_, "ptr_prim", 0);
1600
    return ;
1556
    return;
1601
}
1557
}
1602
 
1558
 
1603
#endif
1559
#endif
1604
 
1560
 
1605
#endif
1561
#endif
Line 1607... Line 1563...
1607
 
1563
 
1608
/* Printing routines for PRIMITIVE */
1564
/* Printing routines for PRIMITIVE */
1609
 
1565
 
1610
#ifndef PRINT_prim
1566
#ifndef PRINT_prim
1611
 
1567
 
1612
static void PRINT_prim
1568
static void
1613
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1614
    PROTO_T ( FILE *f_ X PRIMITIVE x_ X char *nm_ X int d_ )
1569
PRINT_prim(FILE *f_, PRIMITIVE x_, char *nm_, int d_)
1615
{
1570
{
1616
    print_indent ( f_, d_ ) ;
1571
    print_indent(f_, d_);
1617
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1572
    (void)fprintf(f_, "%s = {\n", nm_);
1618
    PRINT_CLASS_ID_P ( f_, x_.id, "id", d_ + 1 ) ;
1573
    PRINT_CLASS_ID_P(f_, x_.id, "id", d_ + 1);
1619
    PRINT_string ( f_, x_.defn, "defn", d_ + 1 ) ;
1574
    PRINT_string(f_, x_.defn, "defn", d_ + 1);
1620
    print_indent ( f_, d_ ) ;
1575
    print_indent(f_, d_);
1621
    ( void ) fprintf ( f_, "}\n" ) ;
1576
    (void)fprintf(f_, "}\n");
1622
    return ;
1577
    return;
1623
}
1578
}
1624
 
1579
 
1625
#ifdef DEBUG
1580
#ifdef DEBUG
1626
 
1581
 
1627
void DEBUG_prim
1582
void
1628
    PROTO_N ( ( x_ ) )
-
 
1629
    PROTO_T ( PRIMITIVE *x_ )
1583
DEBUG_prim(PRIMITIVE *x_)
1630
{
1584
{
1631
    if ( x_ ) PRINT_prim ( stdout, *x_, "prim", 0 ) ;
1585
    if (x_)PRINT_prim(stdout, *x_, "prim", 0);
1632
    return ;
1586
    return;
1633
}
1587
}
1634
 
1588
 
1635
#endif
1589
#endif
1636
 
1590
 
1637
#endif
1591
#endif
1638
 
1592
 
1639
 
1593
 
1640
/* Printing routines for PTR ( MAP ) */
1594
/* Printing routines for PTR(MAP) */
1641
 
1595
 
1642
#ifndef PRINT_ptr_map
1596
#ifndef PRINT_ptr_map
1643
 
1597
 
1644
static void PRINT_ptr_map
1598
static void
1645
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1646
    PROTO_T ( FILE *f_ X PTR ( MAP ) x_ X char *nm_ X int d_ )
1599
PRINT_ptr_map(FILE *f_, PTR(MAP) x_, char *nm_, int d_)
1647
{
1600
{
1648
    print_indent ( f_, d_ ) ;
1601
    print_indent(f_, d_);
1649
    if ( IS_NULL_ptr ( x_ ) ) {
1602
    if (IS_NULL_ptr(x_)) {
1650
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1603
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1651
    } else if ( d_ < print_ptr_depth ) {
1604
    } else if (d_ < print_ptr_depth) {
1652
	MAP z_ ;
1605
	MAP z_;
1653
	DEREF_map ( x_, z_ ) ;
1606
	DEREF_map(x_, z_);
1654
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1607
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1655
	PRINT_map ( f_, z_, "(map)", d_ + 1 ) ;
1608
	PRINT_map(f_, z_, "(map)", d_ + 1);
1656
	print_indent ( f_, d_ ) ;
1609
	print_indent(f_, d_);
1657
	( void ) fprintf ( f_, "}\n" ) ;
1610
	(void)fprintf(f_, "}\n");
1658
    } else {
1611
    } else {
1659
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1612
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1660
    }
1613
    }
1661
    return ;
1614
    return;
1662
}
1615
}
1663
 
1616
 
1664
#ifdef DEBUG
1617
#ifdef DEBUG
1665
 
1618
 
1666
void DEBUG_ptr_map
1619
void
1667
    PROTO_N ( ( x_ ) )
-
 
1668
    PROTO_T ( PTR ( MAP ) x_ )
1620
DEBUG_ptr_map(PTR(MAP) x_)
1669
{
1621
{
1670
    PRINT_ptr_map ( stdout, x_, "ptr_map", 0 ) ;
1622
    PRINT_ptr_map(stdout, x_, "ptr_map", 0);
1671
    return ;
1623
    return;
1672
}
1624
}
1673
 
1625
 
1674
#endif
1626
#endif
1675
 
1627
 
1676
#endif
1628
#endif
Line 1678... Line 1630...
1678
 
1630
 
1679
/* Printing routines for MAP */
1631
/* Printing routines for MAP */
1680
 
1632
 
1681
#ifndef PRINT_map
1633
#ifndef PRINT_map
1682
 
1634
 
1683
static void PRINT_map
1635
static void
1684
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1685
    PROTO_T ( FILE *f_ X MAP x_ X char *nm_ X int d_ )
1636
PRINT_map(FILE *f_, MAP x_, char *nm_, int d_)
1686
{
1637
{
1687
    print_indent ( f_, d_ ) ;
1638
    print_indent(f_, d_);
1688
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1639
    (void)fprintf(f_, "%s = {\n", nm_);
1689
    PRINT_string ( f_, x_.name, "name", d_ + 1 ) ;
1640
    PRINT_string(f_, x_.name, "name", d_ + 1);
1690
    PRINT_int ( f_, x_.flag, "flag", d_ + 1 ) ;
1641
    PRINT_int(f_, x_.flag, "flag", d_ + 1);
1691
    PRINT_TYPE_P ( f_, x_.ret_type, "ret_type", d_ + 1 ) ;
1642
    PRINT_TYPE_P(f_, x_.ret_type, "ret_type", d_ + 1);
1692
    PRINT_list_ARGUMENT_P ( f_, x_.args, "args", d_ + 1 ) ;
1643
    PRINT_list_ARGUMENT_P(f_, x_.args, "args", d_ + 1);
1693
    print_indent ( f_, d_ ) ;
1644
    print_indent(f_, d_);
1694
    ( void ) fprintf ( f_, "}\n" ) ;
1645
    (void)fprintf(f_, "}\n");
1695
    return ;
1646
    return;
1696
}
1647
}
1697
 
1648
 
1698
#ifdef DEBUG
1649
#ifdef DEBUG
1699
 
1650
 
1700
void DEBUG_map
1651
void
1701
    PROTO_N ( ( x_ ) )
-
 
1702
    PROTO_T ( MAP *x_ )
1652
DEBUG_map(MAP *x_)
1703
{
1653
{
1704
    if ( x_ ) PRINT_map ( stdout, *x_, "map", 0 ) ;
1654
    if (x_)PRINT_map(stdout, *x_, "map", 0);
1705
    return ;
1655
    return;
1706
}
1656
}
1707
 
1657
 
1708
#endif
1658
#endif
1709
 
1659
 
1710
#endif
1660
#endif
1711
 
1661
 
1712
 
1662
 
1713
/* Printing routines for PTR ( IDENTITY ) */
1663
/* Printing routines for PTR(IDENTITY) */
1714
 
1664
 
1715
#ifndef PRINT_ptr_ident
1665
#ifndef PRINT_ptr_ident
1716
 
1666
 
1717
static void PRINT_ptr_ident
1667
static void
1718
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1719
    PROTO_T ( FILE *f_ X PTR ( IDENTITY ) x_ X char *nm_ X int d_ )
1668
PRINT_ptr_ident(FILE *f_, PTR(IDENTITY) x_, char *nm_, int d_)
1720
{
1669
{
1721
    print_indent ( f_, d_ ) ;
1670
    print_indent(f_, d_);
1722
    if ( IS_NULL_ptr ( x_ ) ) {
1671
    if (IS_NULL_ptr(x_)) {
1723
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1672
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1724
    } else if ( d_ < print_ptr_depth ) {
1673
    } else if (d_ < print_ptr_depth) {
1725
	IDENTITY z_ ;
1674
	IDENTITY z_;
1726
	DEREF_ident ( x_, z_ ) ;
1675
	DEREF_ident(x_, z_);
1727
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1676
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1728
	PRINT_ident ( f_, z_, "(ident)", d_ + 1 ) ;
1677
	PRINT_ident(f_, z_, "(ident)", d_ + 1);
1729
	print_indent ( f_, d_ ) ;
1678
	print_indent(f_, d_);
1730
	( void ) fprintf ( f_, "}\n" ) ;
1679
	(void)fprintf(f_, "}\n");
1731
    } else {
1680
    } else {
1732
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1681
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1733
    }
1682
    }
1734
    return ;
1683
    return;
1735
}
1684
}
1736
 
1685
 
1737
#ifdef DEBUG
1686
#ifdef DEBUG
1738
 
1687
 
1739
void DEBUG_ptr_ident
1688
void
1740
    PROTO_N ( ( x_ ) )
-
 
1741
    PROTO_T ( PTR ( IDENTITY ) x_ )
1689
DEBUG_ptr_ident(PTR(IDENTITY) x_)
1742
{
1690
{
1743
    PRINT_ptr_ident ( stdout, x_, "ptr_ident", 0 ) ;
1691
    PRINT_ptr_ident(stdout, x_, "ptr_ident", 0);
1744
    return ;
1692
    return;
1745
}
1693
}
1746
 
1694
 
1747
#endif
1695
#endif
1748
 
1696
 
1749
#endif
1697
#endif
Line 1751... Line 1699...
1751
 
1699
 
1752
/* Printing routines for IDENTITY */
1700
/* Printing routines for IDENTITY */
1753
 
1701
 
1754
#ifndef PRINT_ident
1702
#ifndef PRINT_ident
1755
 
1703
 
1756
static void PRINT_ident
1704
static void
1757
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1758
    PROTO_T ( FILE *f_ X IDENTITY x_ X char *nm_ X int d_ )
1705
PRINT_ident(FILE *f_, IDENTITY x_, char *nm_, int d_)
1759
{
1706
{
1760
    print_indent ( f_, d_ ) ;
1707
    print_indent(f_, d_);
1761
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1708
    (void)fprintf(f_, "%s = {\n", nm_);
1762
    PRINT_CLASS_ID_P ( f_, x_.id, "id", d_ + 1 ) ;
1709
    PRINT_CLASS_ID_P(f_, x_.id, "id", d_ + 1);
1763
    PRINT_TYPE_P ( f_, x_.defn, "defn", d_ + 1 ) ;
1710
    PRINT_TYPE_P(f_, x_.defn, "defn", d_ + 1);
1764
    print_indent ( f_, d_ ) ;
1711
    print_indent(f_, d_);
1765
    ( void ) fprintf ( f_, "}\n" ) ;
1712
    (void)fprintf(f_, "}\n");
1766
    return ;
1713
    return;
1767
}
1714
}
1768
 
1715
 
1769
#ifdef DEBUG
1716
#ifdef DEBUG
1770
 
1717
 
1771
void DEBUG_ident
1718
void
1772
    PROTO_N ( ( x_ ) )
-
 
1773
    PROTO_T ( IDENTITY *x_ )
1719
DEBUG_ident(IDENTITY *x_)
1774
{
1720
{
1775
    if ( x_ ) PRINT_ident ( stdout, *x_, "ident", 0 ) ;
1721
    if (x_)PRINT_ident(stdout, *x_, "ident", 0);
1776
    return ;
1722
    return;
1777
}
1723
}
1778
 
1724
 
1779
#endif
1725
#endif
1780
 
1726
 
1781
#endif
1727
#endif
1782
 
1728
 
1783
 
1729
 
1784
/* Printing routines for PTR ( FIELD ) */
1730
/* Printing routines for PTR(FIELD) */
1785
 
1731
 
1786
#ifndef PRINT_ptr_fld
1732
#ifndef PRINT_ptr_fld
1787
 
1733
 
1788
static void PRINT_ptr_fld
1734
static void
1789
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1790
    PROTO_T ( FILE *f_ X PTR ( FIELD ) x_ X char *nm_ X int d_ )
1735
PRINT_ptr_fld(FILE *f_, PTR(FIELD) x_, char *nm_, int d_)
1791
{
1736
{
1792
    print_indent ( f_, d_ ) ;
1737
    print_indent(f_, d_);
1793
    if ( IS_NULL_ptr ( x_ ) ) {
1738
    if (IS_NULL_ptr(x_)) {
1794
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1739
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1795
    } else if ( d_ < print_ptr_depth ) {
1740
    } else if (d_ < print_ptr_depth) {
1796
	FIELD z_ ;
1741
	FIELD z_;
1797
	DEREF_fld ( x_, z_ ) ;
1742
	DEREF_fld(x_, z_);
1798
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1743
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1799
	PRINT_fld ( f_, z_, "(fld)", d_ + 1 ) ;
1744
	PRINT_fld(f_, z_, "(fld)", d_ + 1);
1800
	print_indent ( f_, d_ ) ;
1745
	print_indent(f_, d_);
1801
	( void ) fprintf ( f_, "}\n" ) ;
1746
	(void)fprintf(f_, "}\n");
1802
    } else {
1747
    } else {
1803
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1748
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1804
    }
1749
    }
1805
    return ;
1750
    return;
1806
}
1751
}
1807
 
1752
 
1808
#ifdef DEBUG
1753
#ifdef DEBUG
1809
 
1754
 
1810
void DEBUG_ptr_fld
1755
void
1811
    PROTO_N ( ( x_ ) )
-
 
1812
    PROTO_T ( PTR ( FIELD ) x_ )
1756
DEBUG_ptr_fld(PTR(FIELD) x_)
1813
{
1757
{
1814
    PRINT_ptr_fld ( stdout, x_, "ptr_fld", 0 ) ;
1758
    PRINT_ptr_fld(stdout, x_, "ptr_fld", 0);
1815
    return ;
1759
    return;
1816
}
1760
}
1817
 
1761
 
1818
#endif
1762
#endif
1819
 
1763
 
1820
#endif
1764
#endif
Line 1822... Line 1766...
1822
 
1766
 
1823
/* Printing routines for FIELD */
1767
/* Printing routines for FIELD */
1824
 
1768
 
1825
#ifndef PRINT_fld
1769
#ifndef PRINT_fld
1826
 
1770
 
1827
static void PRINT_fld
1771
static void
1828
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1829
    PROTO_T ( FILE *f_ X FIELD x_ X char *nm_ X int d_ )
1772
PRINT_fld(FILE *f_, FIELD x_, char *nm_, int d_)
1830
{
1773
{
1831
    print_indent ( f_, d_ ) ;
1774
    print_indent(f_, d_);
1832
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1775
    (void)fprintf(f_, "%s = {\n", nm_);
1833
    PRINT_string ( f_, x_.name, "name", d_ + 1 ) ;
1776
    PRINT_string(f_, x_.name, "name", d_ + 1);
1834
    PRINT_int ( f_, x_.tag, "tag", d_ + 1 ) ;
1777
    PRINT_int(f_, x_.tag, "tag", d_ + 1);
1835
    PRINT_int ( f_, x_.flag, "flag", d_ + 1 ) ;
1778
    PRINT_int(f_, x_.flag, "flag", d_ + 1);
1836
    PRINT_int ( f_, x_.set, "set", d_ + 1 ) ;
1779
    PRINT_int(f_, x_.set, "set", d_ + 1);
1837
    PRINT_FIELD_P ( f_, x_.base, "base", d_ + 1 ) ;
1780
    PRINT_FIELD_P(f_, x_.base, "base", d_ + 1);
1838
    PRINT_list_COMPONENT_P ( f_, x_.defn, "defn", d_ + 1 ) ;
1781
    PRINT_list_COMPONENT_P(f_, x_.defn, "defn", d_ + 1);
1839
    print_indent ( f_, d_ ) ;
1782
    print_indent(f_, d_);
1840
    ( void ) fprintf ( f_, "}\n" ) ;
1783
    (void)fprintf(f_, "}\n");
1841
    return ;
1784
    return;
1842
}
1785
}
1843
 
1786
 
1844
#ifdef DEBUG
1787
#ifdef DEBUG
1845
 
1788
 
1846
void DEBUG_fld
1789
void
1847
    PROTO_N ( ( x_ ) )
-
 
1848
    PROTO_T ( FIELD *x_ )
1790
DEBUG_fld(FIELD *x_)
1849
{
1791
{
1850
    if ( x_ ) PRINT_fld ( stdout, *x_, "fld", 0 ) ;
1792
    if (x_)PRINT_fld(stdout, *x_, "fld", 0);
1851
    return ;
1793
    return;
1852
}
1794
}
1853
 
1795
 
1854
#endif
1796
#endif
1855
 
1797
 
1856
#endif
1798
#endif
1857
 
1799
 
1858
 
1800
 
1859
/* Printing routines for PTR ( ENUM ) */
1801
/* Printing routines for PTR(ENUM) */
1860
 
1802
 
1861
#ifndef PRINT_ptr_en
1803
#ifndef PRINT_ptr_en
1862
 
1804
 
1863
static void PRINT_ptr_en
1805
static void
1864
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1865
    PROTO_T ( FILE *f_ X PTR ( ENUM ) x_ X char *nm_ X int d_ )
1806
PRINT_ptr_en(FILE *f_, PTR(ENUM) x_, char *nm_, int d_)
1866
{
1807
{
1867
    print_indent ( f_, d_ ) ;
1808
    print_indent(f_, d_);
1868
    if ( IS_NULL_ptr ( x_ ) ) {
1809
    if (IS_NULL_ptr(x_)) {
1869
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1810
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1870
    } else if ( d_ < print_ptr_depth ) {
1811
    } else if (d_ < print_ptr_depth) {
1871
	ENUM z_ ;
1812
	ENUM z_;
1872
	DEREF_en ( x_, z_ ) ;
1813
	DEREF_en(x_, z_);
1873
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1814
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1874
	PRINT_en ( f_, z_, "(en)", d_ + 1 ) ;
1815
	PRINT_en(f_, z_, "(en)", d_ + 1);
1875
	print_indent ( f_, d_ ) ;
1816
	print_indent(f_, d_);
1876
	( void ) fprintf ( f_, "}\n" ) ;
1817
	(void)fprintf(f_, "}\n");
1877
    } else {
1818
    } else {
1878
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1819
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1879
    }
1820
    }
1880
    return ;
1821
    return;
1881
}
1822
}
1882
 
1823
 
1883
#ifdef DEBUG
1824
#ifdef DEBUG
1884
 
1825
 
1885
void DEBUG_ptr_en
1826
void
1886
    PROTO_N ( ( x_ ) )
-
 
1887
    PROTO_T ( PTR ( ENUM ) x_ )
1827
DEBUG_ptr_en(PTR(ENUM) x_)
1888
{
1828
{
1889
    PRINT_ptr_en ( stdout, x_, "ptr_en", 0 ) ;
1829
    PRINT_ptr_en(stdout, x_, "ptr_en", 0);
1890
    return ;
1830
    return;
1891
}
1831
}
1892
 
1832
 
1893
#endif
1833
#endif
1894
 
1834
 
1895
#endif
1835
#endif
Line 1897... Line 1837...
1897
 
1837
 
1898
/* Printing routines for ENUM */
1838
/* Printing routines for ENUM */
1899
 
1839
 
1900
#ifndef PRINT_en
1840
#ifndef PRINT_en
1901
 
1841
 
1902
static void PRINT_en
1842
static void
1903
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1904
    PROTO_T ( FILE *f_ X ENUM x_ X char *nm_ X int d_ )
1843
PRINT_en(FILE *f_, ENUM x_, char *nm_, int d_)
1905
{
1844
{
1906
    print_indent ( f_, d_ ) ;
1845
    print_indent(f_, d_);
1907
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1846
    (void)fprintf(f_, "%s = {\n", nm_);
1908
    PRINT_CLASS_ID_P ( f_, x_.id, "id", d_ + 1 ) ;
1847
    PRINT_CLASS_ID_P(f_, x_.id, "id", d_ + 1);
1909
    PRINT_list_ECONST_P ( f_, x_.consts, "consts", d_ + 1 ) ;
1848
    PRINT_list_ECONST_P(f_, x_.consts, "consts", d_ + 1);
1910
    PRINT_number ( f_, x_.order, "order", d_ + 1 ) ;
1849
    PRINT_number(f_, x_.order, "order", d_ + 1);
1911
    PRINT_int ( f_, x_.lists, "lists", d_ + 1 ) ;
1850
    PRINT_int(f_, x_.lists, "lists", d_ + 1);
1912
    print_indent ( f_, d_ ) ;
1851
    print_indent(f_, d_);
1913
    ( void ) fprintf ( f_, "}\n" ) ;
1852
    (void)fprintf(f_, "}\n");
1914
    return ;
1853
    return;
1915
}
1854
}
1916
 
1855
 
1917
#ifdef DEBUG
1856
#ifdef DEBUG
1918
 
1857
 
1919
void DEBUG_en
1858
void
1920
    PROTO_N ( ( x_ ) )
-
 
1921
    PROTO_T ( ENUM *x_ )
1859
DEBUG_en(ENUM *x_)
1922
{
1860
{
1923
    if ( x_ ) PRINT_en ( stdout, *x_, "en", 0 ) ;
1861
    if (x_)PRINT_en(stdout, *x_, "en", 0);
1924
    return ;
1862
    return;
1925
}
1863
}
1926
 
1864
 
1927
#endif
1865
#endif
1928
 
1866
 
1929
#endif
1867
#endif
1930
 
1868
 
1931
 
1869
 
1932
/* Printing routines for PTR ( ECONST ) */
1870
/* Printing routines for PTR(ECONST) */
1933
 
1871
 
1934
#ifndef PRINT_ptr_ec
1872
#ifndef PRINT_ptr_ec
1935
 
1873
 
1936
static void PRINT_ptr_ec
1874
static void
1937
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1938
    PROTO_T ( FILE *f_ X PTR ( ECONST ) x_ X char *nm_ X int d_ )
1875
PRINT_ptr_ec(FILE *f_, PTR(ECONST) x_, char *nm_, int d_)
1939
{
1876
{
1940
    print_indent ( f_, d_ ) ;
1877
    print_indent(f_, d_);
1941
    if ( IS_NULL_ptr ( x_ ) ) {
1878
    if (IS_NULL_ptr(x_)) {
1942
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1879
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
1943
    } else if ( d_ < print_ptr_depth ) {
1880
    } else if (d_ < print_ptr_depth) {
1944
	ECONST z_ ;
1881
	ECONST z_;
1945
	DEREF_ec ( x_, z_ ) ;
1882
	DEREF_ec(x_, z_);
1946
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1883
	(void)fprintf(f_, "%s = PTR {\n", nm_);
1947
	PRINT_ec ( f_, z_, "(ec)", d_ + 1 ) ;
1884
	PRINT_ec(f_, z_, "(ec)", d_ + 1);
1948
	print_indent ( f_, d_ ) ;
1885
	print_indent(f_, d_);
1949
	( void ) fprintf ( f_, "}\n" ) ;
1886
	(void)fprintf(f_, "}\n");
1950
    } else {
1887
    } else {
1951
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1888
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
1952
    }
1889
    }
1953
    return ;
1890
    return;
1954
}
1891
}
1955
 
1892
 
1956
#ifdef DEBUG
1893
#ifdef DEBUG
1957
 
1894
 
1958
void DEBUG_ptr_ec
1895
void
1959
    PROTO_N ( ( x_ ) )
-
 
1960
    PROTO_T ( PTR ( ECONST ) x_ )
1896
DEBUG_ptr_ec(PTR(ECONST) x_)
1961
{
1897
{
1962
    PRINT_ptr_ec ( stdout, x_, "ptr_ec", 0 ) ;
1898
    PRINT_ptr_ec(stdout, x_, "ptr_ec", 0);
1963
    return ;
1899
    return;
1964
}
1900
}
1965
 
1901
 
1966
#endif
1902
#endif
1967
 
1903
 
1968
#endif
1904
#endif
Line 1970... Line 1906...
1970
 
1906
 
1971
/* Printing routines for ECONST */
1907
/* Printing routines for ECONST */
1972
 
1908
 
1973
#ifndef PRINT_ec
1909
#ifndef PRINT_ec
1974
 
1910
 
1975
static void PRINT_ec
1911
static void
1976
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
1977
    PROTO_T ( FILE *f_ X ECONST x_ X char *nm_ X int d_ )
1912
PRINT_ec(FILE *f_, ECONST x_, char *nm_, int d_)
1978
{
1913
{
1979
    print_indent ( f_, d_ ) ;
1914
    print_indent(f_, d_);
1980
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1915
    (void)fprintf(f_, "%s = {\n", nm_);
1981
    PRINT_string ( f_, x_.name, "name", d_ + 1 ) ;
1916
    PRINT_string(f_, x_.name, "name", d_ + 1);
1982
    PRINT_number ( f_, x_.value, "value", d_ + 1 ) ;
1917
    PRINT_number(f_, x_.value, "value", d_ + 1);
1983
    print_indent ( f_, d_ ) ;
1918
    print_indent(f_, d_);
1984
    ( void ) fprintf ( f_, "}\n" ) ;
1919
    (void)fprintf(f_, "}\n");
1985
    return ;
1920
    return;
1986
}
1921
}
1987
 
1922
 
1988
#ifdef DEBUG
1923
#ifdef DEBUG
1989
 
1924
 
1990
void DEBUG_ec
1925
void
1991
    PROTO_N ( ( x_ ) )
-
 
1992
    PROTO_T ( ECONST *x_ )
1926
DEBUG_ec(ECONST *x_)
1993
{
1927
{
1994
    if ( x_ ) PRINT_ec ( stdout, *x_, "ec", 0 ) ;
1928
    if (x_)PRINT_ec(stdout, *x_, "ec", 0);
1995
    return ;
1929
    return;
1996
}
1930
}
1997
 
1931
 
1998
#endif
1932
#endif
1999
 
1933
 
2000
#endif
1934
#endif
2001
 
1935
 
2002
 
1936
 
2003
/* Printing routines for PTR ( COMPONENT ) */
1937
/* Printing routines for PTR(COMPONENT) */
2004
 
1938
 
2005
#ifndef PRINT_ptr_cmp
1939
#ifndef PRINT_ptr_cmp
2006
 
1940
 
2007
static void PRINT_ptr_cmp
1941
static void
2008
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2009
    PROTO_T ( FILE *f_ X PTR ( COMPONENT ) x_ X char *nm_ X int d_ )
1942
PRINT_ptr_cmp(FILE *f_, PTR(COMPONENT) x_, char *nm_, int d_)
2010
{
1943
{
2011
    print_indent ( f_, d_ ) ;
1944
    print_indent(f_, d_);
2012
    if ( IS_NULL_ptr ( x_ ) ) {
1945
    if (IS_NULL_ptr(x_)) {
2013
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
1946
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
2014
    } else if ( d_ < print_ptr_depth ) {
1947
    } else if (d_ < print_ptr_depth) {
2015
	COMPONENT z_ ;
1948
	COMPONENT z_;
2016
	DEREF_cmp ( x_, z_ ) ;
1949
	DEREF_cmp(x_, z_);
2017
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
1950
	(void)fprintf(f_, "%s = PTR {\n", nm_);
2018
	PRINT_cmp ( f_, z_, "(cmp)", d_ + 1 ) ;
1951
	PRINT_cmp(f_, z_, "(cmp)", d_ + 1);
2019
	print_indent ( f_, d_ ) ;
1952
	print_indent(f_, d_);
2020
	( void ) fprintf ( f_, "}\n" ) ;
1953
	(void)fprintf(f_, "}\n");
2021
    } else {
1954
    } else {
2022
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
1955
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
2023
    }
1956
    }
2024
    return ;
1957
    return;
2025
}
1958
}
2026
 
1959
 
2027
#ifdef DEBUG
1960
#ifdef DEBUG
2028
 
1961
 
2029
void DEBUG_ptr_cmp
1962
void
2030
    PROTO_N ( ( x_ ) )
-
 
2031
    PROTO_T ( PTR ( COMPONENT ) x_ )
1963
DEBUG_ptr_cmp(PTR(COMPONENT) x_)
2032
{
1964
{
2033
    PRINT_ptr_cmp ( stdout, x_, "ptr_cmp", 0 ) ;
1965
    PRINT_ptr_cmp(stdout, x_, "ptr_cmp", 0);
2034
    return ;
1966
    return;
2035
}
1967
}
2036
 
1968
 
2037
#endif
1969
#endif
2038
 
1970
 
2039
#endif
1971
#endif
Line 2041... Line 1973...
2041
 
1973
 
2042
/* Printing routines for COMPONENT */
1974
/* Printing routines for COMPONENT */
2043
 
1975
 
2044
#ifndef PRINT_cmp
1976
#ifndef PRINT_cmp
2045
 
1977
 
2046
static void PRINT_cmp
1978
static void
2047
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2048
    PROTO_T ( FILE *f_ X COMPONENT x_ X char *nm_ X int d_ )
1979
PRINT_cmp(FILE *f_, COMPONENT x_, char *nm_, int d_)
2049
{
1980
{
2050
    print_indent ( f_, d_ ) ;
1981
    print_indent(f_, d_);
2051
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
1982
    (void)fprintf(f_, "%s = {\n", nm_);
2052
    PRINT_string ( f_, x_.name, "name", d_ + 1 ) ;
1983
    PRINT_string(f_, x_.name, "name", d_ + 1);
2053
    PRINT_TYPE_P ( f_, x_.type, "type", d_ + 1 ) ;
1984
    PRINT_TYPE_P(f_, x_.type, "type", d_ + 1);
2054
    PRINT_string ( f_, x_.value, "value", d_ + 1 ) ;
1985
    PRINT_string(f_, x_.value, "value", d_ + 1);
2055
    print_indent ( f_, d_ ) ;
1986
    print_indent(f_, d_);
2056
    ( void ) fprintf ( f_, "}\n" ) ;
1987
    (void)fprintf(f_, "}\n");
2057
    return ;
1988
    return;
2058
}
1989
}
2059
 
1990
 
2060
#ifdef DEBUG
1991
#ifdef DEBUG
2061
 
1992
 
2062
void DEBUG_cmp
1993
void
2063
    PROTO_N ( ( x_ ) )
-
 
2064
    PROTO_T ( COMPONENT *x_ )
1994
DEBUG_cmp(COMPONENT *x_)
2065
{
1995
{
2066
    if ( x_ ) PRINT_cmp ( stdout, *x_, "cmp", 0 ) ;
1996
    if (x_)PRINT_cmp(stdout, *x_, "cmp", 0);
2067
    return ;
1997
    return;
2068
}
1998
}
2069
 
1999
 
2070
#endif
2000
#endif
2071
 
2001
 
2072
#endif
2002
#endif
2073
 
2003
 
2074
 
2004
 
2075
/* Printing routines for PTR ( PTR ( CLASS_ID ) ) */
2005
/* Printing routines for PTR(PTR(CLASS_ID)) */
2076
 
2006
 
2077
#ifndef PRINT_ptr_ptr_cid
2007
#ifndef PRINT_ptr_ptr_cid
2078
 
2008
 
2079
static void PRINT_ptr_ptr_cid
2009
static void
2080
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2081
    PROTO_T ( FILE *f_ X PTR ( PTR ( CLASS_ID ) ) x_ X char *nm_ X int d_ )
2010
PRINT_ptr_ptr_cid(FILE *f_, PTR(PTR(CLASS_ID)) x_, char *nm_, int d_)
2082
{
2011
{
2083
    print_indent ( f_, d_ ) ;
2012
    print_indent(f_, d_);
2084
    if ( IS_NULL_ptr ( x_ ) ) {
2013
    if (IS_NULL_ptr(x_)) {
2085
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
2014
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
2086
    } else if ( d_ < print_ptr_depth ) {
2015
    } else if (d_ < print_ptr_depth) {
2087
	PTR ( CLASS_ID ) z_ ;
2016
	PTR(CLASS_ID) z_;
2088
	z_ = DEREF_ptr ( x_ ) ;
2017
	z_ = DEREF_ptr(x_);
2089
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
2018
	(void)fprintf(f_, "%s = PTR {\n", nm_);
2090
	PRINT_ptr_cid ( f_, z_, "(ptr_cid)", d_ + 1 ) ;
2019
	PRINT_ptr_cid(f_, z_, "(ptr_cid)", d_ + 1);
2091
	print_indent ( f_, d_ ) ;
2020
	print_indent(f_, d_);
2092
	( void ) fprintf ( f_, "}\n" ) ;
2021
	(void)fprintf(f_, "}\n");
2093
    } else {
2022
    } else {
2094
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
2023
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
2095
    }
2024
    }
2096
    return ;
2025
    return;
2097
}
2026
}
2098
 
2027
 
2099
#ifdef DEBUG
2028
#ifdef DEBUG
2100
 
2029
 
2101
void DEBUG_ptr_ptr_cid
2030
void
2102
    PROTO_N ( ( x_ ) )
-
 
2103
    PROTO_T ( PTR ( PTR ( CLASS_ID ) ) x_ )
2031
DEBUG_ptr_ptr_cid(PTR(PTR(CLASS_ID)) x_)
2104
{
2032
{
2105
    PRINT_ptr_ptr_cid ( stdout, x_, "ptr_ptr_cid", 0 ) ;
2033
    PRINT_ptr_ptr_cid(stdout, x_, "ptr_ptr_cid", 0);
2106
    return ;
2034
    return;
2107
}
2035
}
2108
 
2036
 
2109
#endif
2037
#endif
2110
 
2038
 
2111
#endif
2039
#endif
2112
 
2040
 
2113
 
2041
 
2114
/* Printing routines for PTR ( CLASS_ID ) */
2042
/* Printing routines for PTR(CLASS_ID) */
2115
 
2043
 
2116
#ifndef PRINT_ptr_cid
2044
#ifndef PRINT_ptr_cid
2117
 
2045
 
2118
static void PRINT_ptr_cid
2046
static void
2119
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2120
    PROTO_T ( FILE *f_ X PTR ( CLASS_ID ) x_ X char *nm_ X int d_ )
2047
PRINT_ptr_cid(FILE *f_, PTR(CLASS_ID) x_, char *nm_, int d_)
2121
{
2048
{
2122
    print_indent ( f_, d_ ) ;
2049
    print_indent(f_, d_);
2123
    if ( IS_NULL_ptr ( x_ ) ) {
2050
    if (IS_NULL_ptr(x_)) {
2124
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
2051
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
2125
    } else if ( d_ < print_ptr_depth ) {
2052
    } else if (d_ < print_ptr_depth) {
2126
	CLASS_ID z_ ;
2053
	CLASS_ID z_;
2127
	DEREF_cid ( x_, z_ ) ;
2054
	DEREF_cid(x_, z_);
2128
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
2055
	(void)fprintf(f_, "%s = PTR {\n", nm_);
2129
	PRINT_cid ( f_, z_, "(cid)", d_ + 1 ) ;
2056
	PRINT_cid(f_, z_, "(cid)", d_ + 1);
2130
	print_indent ( f_, d_ ) ;
2057
	print_indent(f_, d_);
2131
	( void ) fprintf ( f_, "}\n" ) ;
2058
	(void)fprintf(f_, "}\n");
2132
    } else {
2059
    } else {
2133
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
2060
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
2134
    }
2061
    }
2135
    return ;
2062
    return;
2136
}
2063
}
2137
 
2064
 
2138
#ifdef DEBUG
2065
#ifdef DEBUG
2139
 
2066
 
2140
void DEBUG_ptr_cid
2067
void
2141
    PROTO_N ( ( x_ ) )
-
 
2142
    PROTO_T ( PTR ( CLASS_ID ) x_ )
2068
DEBUG_ptr_cid(PTR(CLASS_ID) x_)
2143
{
2069
{
2144
    PRINT_ptr_cid ( stdout, x_, "ptr_cid", 0 ) ;
2070
    PRINT_ptr_cid(stdout, x_, "ptr_cid", 0);
2145
    return ;
2071
    return;
2146
}
2072
}
2147
 
2073
 
2148
#endif
2074
#endif
2149
 
2075
 
2150
#endif
2076
#endif
Line 2152... Line 2078...
2152
 
2078
 
2153
/* Printing routines for CLASS_ID */
2079
/* Printing routines for CLASS_ID */
2154
 
2080
 
2155
#ifndef PRINT_cid
2081
#ifndef PRINT_cid
2156
 
2082
 
2157
static void PRINT_cid
2083
static void
2158
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2159
    PROTO_T ( FILE *f_ X CLASS_ID x_ X char *nm_ X int d_ )
2084
PRINT_cid(FILE *f_, CLASS_ID x_, char *nm_, int d_)
2160
{
2085
{
2161
    print_indent ( f_, d_ ) ;
2086
    print_indent(f_, d_);
2162
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
2087
    (void)fprintf(f_, "%s = {\n", nm_);
2163
    PRINT_string ( f_, x_.name, "name", d_ + 1 ) ;
2088
    PRINT_string(f_, x_.name, "name", d_ + 1);
2164
    PRINT_string ( f_, x_.name_aux, "name_aux", d_ + 1 ) ;
2089
    PRINT_string(f_, x_.name_aux, "name_aux", d_ + 1);
2165
    PRINT_int ( f_, x_.flag, "flag", d_ + 1 ) ;
2090
    PRINT_int(f_, x_.flag, "flag", d_ + 1);
2166
    PRINT_name_string ( f_, x_.file, "file", d_ + 1 ) ;
2091
    PRINT_name_string(f_, x_.file, "file", d_ + 1);
2167
    PRINT_int ( f_, x_.line, "line", d_ + 1 ) ;
2092
    PRINT_int(f_, x_.line, "line", d_ + 1);
2168
    print_indent ( f_, d_ ) ;
2093
    print_indent(f_, d_);
2169
    ( void ) fprintf ( f_, "}\n" ) ;
2094
    (void)fprintf(f_, "}\n");
2170
    return ;
2095
    return;
2171
}
2096
}
2172
 
2097
 
2173
#ifdef DEBUG
2098
#ifdef DEBUG
2174
 
2099
 
2175
void DEBUG_cid
2100
void
2176
    PROTO_N ( ( x_ ) )
-
 
2177
    PROTO_T ( CLASS_ID *x_ )
2101
DEBUG_cid(CLASS_ID *x_)
2178
{
2102
{
2179
    if ( x_ ) PRINT_cid ( stdout, *x_, "cid", 0 ) ;
2103
    if (x_)PRINT_cid(stdout, *x_, "cid", 0);
2180
    return ;
2104
    return;
2181
}
2105
}
2182
 
2106
 
2183
#endif
2107
#endif
2184
 
2108
 
2185
#endif
2109
#endif
2186
 
2110
 
2187
 
2111
 
2188
/* Printing routines for PTR ( ARGUMENT ) */
2112
/* Printing routines for PTR(ARGUMENT) */
2189
 
2113
 
2190
#ifndef PRINT_ptr_arg
2114
#ifndef PRINT_ptr_arg
2191
 
2115
 
2192
static void PRINT_ptr_arg
2116
static void
2193
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2194
    PROTO_T ( FILE *f_ X PTR ( ARGUMENT ) x_ X char *nm_ X int d_ )
2117
PRINT_ptr_arg(FILE *f_, PTR(ARGUMENT) x_, char *nm_, int d_)
2195
{
2118
{
2196
    print_indent ( f_, d_ ) ;
2119
    print_indent(f_, d_);
2197
    if ( IS_NULL_ptr ( x_ ) ) {
2120
    if (IS_NULL_ptr(x_)) {
2198
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
2121
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
2199
    } else if ( d_ < print_ptr_depth ) {
2122
    } else if (d_ < print_ptr_depth) {
2200
	ARGUMENT z_ ;
2123
	ARGUMENT z_;
2201
	DEREF_arg ( x_, z_ ) ;
2124
	DEREF_arg(x_, z_);
2202
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
2125
	(void)fprintf(f_, "%s = PTR {\n", nm_);
2203
	PRINT_arg ( f_, z_, "(arg)", d_ + 1 ) ;
2126
	PRINT_arg(f_, z_, "(arg)", d_ + 1);
2204
	print_indent ( f_, d_ ) ;
2127
	print_indent(f_, d_);
2205
	( void ) fprintf ( f_, "}\n" ) ;
2128
	(void)fprintf(f_, "}\n");
2206
    } else {
2129
    } else {
2207
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
2130
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
2208
    }
2131
    }
2209
    return ;
2132
    return;
2210
}
2133
}
2211
 
2134
 
2212
#ifdef DEBUG
2135
#ifdef DEBUG
2213
 
2136
 
2214
void DEBUG_ptr_arg
2137
void
2215
    PROTO_N ( ( x_ ) )
-
 
2216
    PROTO_T ( PTR ( ARGUMENT ) x_ )
2138
DEBUG_ptr_arg(PTR(ARGUMENT) x_)
2217
{
2139
{
2218
    PRINT_ptr_arg ( stdout, x_, "ptr_arg", 0 ) ;
2140
    PRINT_ptr_arg(stdout, x_, "ptr_arg", 0);
2219
    return ;
2141
    return;
2220
}
2142
}
2221
 
2143
 
2222
#endif
2144
#endif
2223
 
2145
 
2224
#endif
2146
#endif
Line 2226... Line 2148...
2226
 
2148
 
2227
/* Printing routines for ARGUMENT */
2149
/* Printing routines for ARGUMENT */
2228
 
2150
 
2229
#ifndef PRINT_arg
2151
#ifndef PRINT_arg
2230
 
2152
 
2231
static void PRINT_arg
2153
static void
2232
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2233
    PROTO_T ( FILE *f_ X ARGUMENT x_ X char *nm_ X int d_ )
2154
PRINT_arg(FILE *f_, ARGUMENT x_, char *nm_, int d_)
2234
{
2155
{
2235
    print_indent ( f_, d_ ) ;
2156
    print_indent(f_, d_);
2236
    ( void ) fprintf ( f_, "%s = {\n", nm_ ) ;
2157
    (void)fprintf(f_, "%s = {\n", nm_);
2237
    PRINT_string ( f_, x_.name, "name", d_ + 1 ) ;
2158
    PRINT_string(f_, x_.name, "name", d_ + 1);
2238
    PRINT_TYPE_P ( f_, x_.type, "type", d_ + 1 ) ;
2159
    PRINT_TYPE_P(f_, x_.type, "type", d_ + 1);
2239
    print_indent ( f_, d_ ) ;
2160
    print_indent(f_, d_);
2240
    ( void ) fprintf ( f_, "}\n" ) ;
2161
    (void)fprintf(f_, "}\n");
2241
    return ;
2162
    return;
2242
}
2163
}
2243
 
2164
 
2244
#ifdef DEBUG
2165
#ifdef DEBUG
2245
 
2166
 
2246
void DEBUG_arg
2167
void
2247
    PROTO_N ( ( x_ ) )
-
 
2248
    PROTO_T ( ARGUMENT *x_ )
2168
DEBUG_arg(ARGUMENT *x_)
2249
{
2169
{
2250
    if ( x_ ) PRINT_arg ( stdout, *x_, "arg", 0 ) ;
2170
    if (x_)PRINT_arg(stdout, *x_, "arg", 0);
2251
    return ;
2171
    return;
2252
}
2172
}
2253
 
2173
 
2254
#endif
2174
#endif
2255
 
2175
 
2256
#endif
2176
#endif
2257
 
2177
 
2258
 
2178
 
2259
/* Printing routines for PTR ( string ) */
2179
/* Printing routines for PTR(string) */
2260
 
2180
 
2261
#ifndef PRINT_ptr_string
2181
#ifndef PRINT_ptr_string
2262
 
2182
 
2263
static void PRINT_ptr_string
2183
static void
2264
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2265
    PROTO_T ( FILE *f_ X PTR ( string ) x_ X char *nm_ X int d_ )
2184
PRINT_ptr_string(FILE *f_, PTR(string) x_, char *nm_, int d_)
2266
{
2185
{
2267
    print_indent ( f_, d_ ) ;
2186
    print_indent(f_, d_);
2268
    if ( IS_NULL_ptr ( x_ ) ) {
2187
    if (IS_NULL_ptr(x_)) {
2269
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
2188
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
2270
    } else if ( d_ < print_ptr_depth ) {
2189
    } else if (d_ < print_ptr_depth) {
2271
	string z_ ;
2190
	string z_;
2272
	z_ = DEREF_string ( x_ ) ;
2191
	z_ = DEREF_string(x_);
2273
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
2192
	(void)fprintf(f_, "%s = PTR {\n", nm_);
2274
	PRINT_string ( f_, z_, "(string)", d_ + 1 ) ;
2193
	PRINT_string(f_, z_, "(string)", d_ + 1);
2275
	print_indent ( f_, d_ ) ;
2194
	print_indent(f_, d_);
2276
	( void ) fprintf ( f_, "}\n" ) ;
2195
	(void)fprintf(f_, "}\n");
2277
    } else {
2196
    } else {
2278
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
2197
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
2279
    }
2198
    }
2280
    return ;
2199
    return;
2281
}
2200
}
2282
 
2201
 
2283
#ifdef DEBUG
2202
#ifdef DEBUG
2284
 
2203
 
2285
void DEBUG_ptr_string
2204
void
2286
    PROTO_N ( ( x_ ) )
-
 
2287
    PROTO_T ( PTR ( string ) x_ )
2205
DEBUG_ptr_string(PTR(string) x_)
2288
{
2206
{
2289
    PRINT_ptr_string ( stdout, x_, "ptr_string", 0 ) ;
2207
    PRINT_ptr_string(stdout, x_, "ptr_string", 0);
2290
    return ;
2208
    return;
2291
}
2209
}
2292
 
2210
 
2293
#endif
2211
#endif
2294
 
2212
 
2295
#endif
2213
#endif
2296
 
2214
 
2297
 
2215
 
2298
/* Printing routines for PTR ( number ) */
2216
/* Printing routines for PTR(number) */
2299
 
2217
 
2300
#ifndef PRINT_ptr_number
2218
#ifndef PRINT_ptr_number
2301
 
2219
 
2302
static void PRINT_ptr_number
2220
static void
2303
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2304
    PROTO_T ( FILE *f_ X PTR ( number ) x_ X char *nm_ X int d_ )
2221
PRINT_ptr_number(FILE *f_, PTR(number) x_, char *nm_, int d_)
2305
{
2222
{
2306
    print_indent ( f_, d_ ) ;
2223
    print_indent(f_, d_);
2307
    if ( IS_NULL_ptr ( x_ ) ) {
2224
    if (IS_NULL_ptr(x_)) {
2308
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
2225
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
2309
    } else if ( d_ < print_ptr_depth ) {
2226
    } else if (d_ < print_ptr_depth) {
2310
	number z_ ;
2227
	number z_;
2311
	z_ = DEREF_number ( x_ ) ;
2228
	z_ = DEREF_number(x_);
2312
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
2229
	(void)fprintf(f_, "%s = PTR {\n", nm_);
2313
	PRINT_number ( f_, z_, "(number)", d_ + 1 ) ;
2230
	PRINT_number(f_, z_, "(number)", d_ + 1);
2314
	print_indent ( f_, d_ ) ;
2231
	print_indent(f_, d_);
2315
	( void ) fprintf ( f_, "}\n" ) ;
2232
	(void)fprintf(f_, "}\n");
2316
    } else {
2233
    } else {
2317
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
2234
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
2318
    }
2235
    }
2319
    return ;
2236
    return;
2320
}
2237
}
2321
 
2238
 
2322
#ifdef DEBUG
2239
#ifdef DEBUG
2323
 
2240
 
2324
void DEBUG_ptr_number
2241
void
2325
    PROTO_N ( ( x_ ) )
-
 
2326
    PROTO_T ( PTR ( number ) x_ )
2242
DEBUG_ptr_number(PTR(number) x_)
2327
{
2243
{
2328
    PRINT_ptr_number ( stdout, x_, "ptr_number", 0 ) ;
2244
    PRINT_ptr_number(stdout, x_, "ptr_number", 0);
2329
    return ;
2245
    return;
2330
}
2246
}
2331
 
2247
 
2332
#endif
2248
#endif
2333
 
2249
 
2334
#endif
2250
#endif
2335
 
2251
 
2336
 
2252
 
2337
/* Printing routines for PTR ( int ) */
2253
/* Printing routines for PTR(int) */
2338
 
2254
 
2339
#ifndef PRINT_ptr_int
2255
#ifndef PRINT_ptr_int
2340
 
2256
 
2341
static void PRINT_ptr_int
2257
static void
2342
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2343
    PROTO_T ( FILE *f_ X PTR ( int ) x_ X char *nm_ X int d_ )
2258
PRINT_ptr_int(FILE *f_, PTR(int) x_, char *nm_, int d_)
2344
{
2259
{
2345
    print_indent ( f_, d_ ) ;
2260
    print_indent(f_, d_);
2346
    if ( IS_NULL_ptr ( x_ ) ) {
2261
    if (IS_NULL_ptr(x_)) {
2347
	( void ) fprintf ( f_, "%s = NULL_ptr ;\n", nm_ ) ;
2262
	(void)fprintf(f_, "%s = NULL_ptr;\n", nm_);
2348
    } else if ( d_ < print_ptr_depth ) {
2263
    } else if (d_ < print_ptr_depth) {
2349
	int z_ ;
2264
	int z_;
2350
	z_ = DEREF_int ( x_ ) ;
2265
	z_ = DEREF_int(x_);
2351
	( void ) fprintf ( f_, "%s = PTR {\n", nm_ ) ;
2266
	(void)fprintf(f_, "%s = PTR {\n", nm_);
2352
	PRINT_int ( f_, z_, "(int)", d_ + 1 ) ;
2267
	PRINT_int(f_, z_, "(int)", d_ + 1);
2353
	print_indent ( f_, d_ ) ;
2268
	print_indent(f_, d_);
2354
	( void ) fprintf ( f_, "}\n" ) ;
2269
	(void)fprintf(f_, "}\n");
2355
    } else {
2270
    } else {
2356
	( void ) fprintf ( f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr ( x_ ) ) ;
2271
	(void)fprintf(f_, "%s = 0x%p ;\n", nm_, VOIDSTAR_ptr(x_));
2357
    }
2272
    }
2358
    return ;
2273
    return;
2359
}
2274
}
2360
 
2275
 
2361
#ifdef DEBUG
2276
#ifdef DEBUG
2362
 
2277
 
2363
void DEBUG_ptr_int
2278
void
2364
    PROTO_N ( ( x_ ) )
-
 
2365
    PROTO_T ( PTR ( int ) x_ )
2279
DEBUG_ptr_int(PTR(int) x_)
2366
{
2280
{
2367
    PRINT_ptr_int ( stdout, x_, "ptr_int", 0 ) ;
2281
    PRINT_ptr_int(stdout, x_, "ptr_int", 0);
2368
    return ;
2282
    return;
2369
}
2283
}
2370
 
2284
 
2371
#endif
2285
#endif
2372
 
2286
 
2373
#endif
2287
#endif
Line 2375... Line 2289...
2375
 
2289
 
2376
/* Printing routines for string */
2290
/* Printing routines for string */
2377
 
2291
 
2378
#ifndef PRINT_string
2292
#ifndef PRINT_string
2379
 
2293
 
2380
static void PRINT_string
2294
static void
2381
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2382
    PROTO_T ( FILE *f_ X string x_ X char *nm_ X int d_ )
2295
PRINT_string(FILE *f_, string x_, char *nm_, int d_)
2383
{
2296
{
2384
    print_indent ( f_, d_ ) ;
2297
    print_indent(f_, d_);
2385
    ( void ) fprintf ( f_, "%s = ", nm_ ) ;
2298
    (void)fprintf(f_, "%s = ", nm_);
2386
    OUTPUT_string ( f_, x_ ) ;
2299
    OUTPUT_string(f_, x_);
2387
    ( void ) fprintf ( f_, " ;\n" ) ;
2300
    (void)fprintf(f_, " ;\n");
2388
    return ;
2301
    return;
2389
}
2302
}
2390
 
2303
 
2391
#ifdef DEBUG
2304
#ifdef DEBUG
2392
 
2305
 
2393
void DEBUG_string
2306
void
2394
    PROTO_N ( ( x_ ) )
-
 
2395
    PROTO_T ( string x_ )
2307
DEBUG_string(string x_)
2396
{
2308
{
2397
    PRINT_string ( stdout, x_, "string", 0 ) ;
2309
    PRINT_string(stdout, x_, "string", 0);
2398
    return ;
2310
    return;
2399
}
2311
}
2400
 
2312
 
2401
#endif
2313
#endif
2402
 
2314
 
2403
#endif
2315
#endif
Line 2405... Line 2317...
2405
 
2317
 
2406
/* Printing routines for number */
2318
/* Printing routines for number */
2407
 
2319
 
2408
#ifndef PRINT_number
2320
#ifndef PRINT_number
2409
 
2321
 
2410
static void PRINT_number
2322
static void
2411
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2412
    PROTO_T ( FILE *f_ X number x_ X char *nm_ X int d_ )
2323
PRINT_number(FILE *f_, number x_, char *nm_, int d_)
2413
{
2324
{
2414
    print_indent ( f_, d_ ) ;
2325
    print_indent(f_, d_);
2415
    ( void ) fprintf ( f_, "%s = ", nm_ ) ;
2326
    (void)fprintf(f_, "%s = ", nm_);
2416
    OUTPUT_number ( f_, x_ ) ;
2327
    OUTPUT_number(f_, x_);
2417
    ( void ) fprintf ( f_, " ;\n" ) ;
2328
    (void)fprintf(f_, " ;\n");
2418
    return ;
2329
    return;
2419
}
2330
}
2420
 
2331
 
2421
#ifdef DEBUG
2332
#ifdef DEBUG
2422
 
2333
 
2423
void DEBUG_number
2334
void
2424
    PROTO_N ( ( x_ ) )
-
 
2425
    PROTO_T ( number x_ )
2335
DEBUG_number(number x_)
2426
{
2336
{
2427
    PRINT_number ( stdout, x_, "number", 0 ) ;
2337
    PRINT_number(stdout, x_, "number", 0);
2428
    return ;
2338
    return;
2429
}
2339
}
2430
 
2340
 
2431
#endif
2341
#endif
2432
 
2342
 
2433
#endif
2343
#endif
Line 2435... Line 2345...
2435
 
2345
 
2436
/* Printing routines for int */
2346
/* Printing routines for int */
2437
 
2347
 
2438
#ifndef PRINT_int
2348
#ifndef PRINT_int
2439
 
2349
 
2440
static void PRINT_int
2350
static void
2441
    PROTO_N ( ( f_, x_, nm_, d_ ) )
-
 
2442
    PROTO_T ( FILE *f_ X int x_ X char *nm_ X int d_ )
2351
PRINT_int(FILE *f_, int x_, char *nm_, int d_)
2443
{
2352
{
2444
    print_indent ( f_, d_ ) ;
2353
    print_indent(f_, d_);
2445
    ( void ) fprintf ( f_, "%s = ", nm_ ) ;
2354
    (void)fprintf(f_, "%s = ", nm_);
2446
    OUTPUT_int ( f_, x_ ) ;
2355
    OUTPUT_int(f_, x_);
2447
    ( void ) fprintf ( f_, " ;\n" ) ;
2356
    (void)fprintf(f_, " ;\n");
2448
    return ;
2357
    return;
2449
}
2358
}
2450
 
2359
 
2451
#ifdef DEBUG
2360
#ifdef DEBUG
2452
 
2361
 
2453
void DEBUG_int
2362
void
2454
    PROTO_N ( ( x_ ) )
-
 
2455
    PROTO_T ( int x_ )
2363
DEBUG_int(int x_)
2456
{
2364
{
2457
    PRINT_int ( stdout, x_, "int", 0 ) ;
2365
    PRINT_int(stdout, x_, "int", 0);
2458
    return ;
2366
    return;
2459
}
2367
}
2460
 
2368
 
2461
#endif
2369
#endif
2462
 
2370
 
2463
#endif
2371
#endif