Subversion Repositories tendra.SVN

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 7u83 1
/*
2
    		 Crown Copyright (c) 1997
3
 
4
    This TenDRA(r) Computer Program is subject to Copyright
5
    owned by the United Kingdom Secretary of State for Defence
6
    acting through the Defence Evaluation and Research Agency
7
    (DERA).  It is made available to Recipients with a
8
    royalty-free licence for its use, reproduction, transfer
9
    to other parties and amendment for any purpose not excluding
10
    product development provided that any such use et cetera
11
    shall be deemed to be acceptance of the following conditions:-
12
 
13
        (1) Its Recipients shall ensure that this Notice is
14
        reproduced upon any copies or amended versions of it;
15
 
16
        (2) Any amended version of it shall be clearly marked to
17
        show both the nature of and the organisation responsible
18
        for the relevant amendment or amendments;
19
 
20
        (3) Its onward transfer from a recipient to another
21
        party shall be deemed to be that party's acceptance of
22
        these conditions;
23
 
24
        (4) DERA gives no warranty or assurance as to its
25
        quality or suitability for any purpose and DERA accepts
26
        no liability whatsoever in relation to any use to which
27
        it may be put.
28
*/
29
 
30
/*
31
    AUTOMATICALLY GENERATED FROM ALGEBRA calculus (VERSION 1.2)
32
    BY calculus (VERSION 1.2)
33
*/
34
 
35
#ifndef CALCULUS_H_INCLUDED
36
#define CALCULUS_H_INCLUDED
37
 
38
#ifndef calculus_NAME
39
#define calculus_NAME			"calculus"
40
#define calculus_VERSION		"1.2"
41
#define calculus_SPECIFICATION		0
42
#define calculus_IMPLEMENTATION		1
43
#endif
44
 
45
 
46
/* Prototype macros */
47
 
48
#ifndef PROTO_S
49
#ifdef __STDC__
50
#define PROTO_S( types )		types
51
#define PROTO_N( names )
52
#define PROTO_T( parms )		( parms )
53
#define PROTO_Z()			( void )
54
#define X				,
55
#else
56
#define PROTO_S( types )		()
57
#define PROTO_N( names )		names
58
#define PROTO_T( parms )		parms ;
59
#define PROTO_Z()			()
60
#define X				;
61
#endif
62
#endif
63
 
64
#ifndef CONST_S
65
#define CONST_S
66
#endif
67
 
68
 
69
/* Primitive types */
70
 
71
typedef unsigned long number ;
72
typedef char * string ;
73
 
74
 
75
/* Basic types */
76
 
77
typedef union calculus_tag {
78
    unsigned ag_tag ;
79
    union calculus_tag *ag_ptr ;
80
    unsigned ag_enum ;
81
    unsigned long ag_long_enum ;
82
    int ag_prim_int ;
83
    number ag_prim_number ;
84
    string ag_prim_string ;
85
} calculus ;
86
 
87
typedef calculus *calculus_PTR ;
88
 
89
#ifndef calculus_DESTR_DEFINED
90
#define calculus_DESTR_DEFINED
91
typedef void ( *DESTROYER ) PROTO_S ( ( calculus *, unsigned ) ) ;
92
#endif
93
 
94
#define PTR( A )	calculus_PTR
95
#define LIST( A )	calculus_PTR
96
#define STACK( A )	calculus_PTR
97
#define SIZE( A )	int
98
 
99
 
100
/* Assertion macros */
101
 
102
#ifdef ASSERTS
103
extern calculus *check_null_calculus PROTO_S ( ( calculus *, CONST_S char *, int ) ) ;
104
extern calculus *check_tag_calculus PROTO_S ( ( calculus *, unsigned, CONST_S char *, int ) ) ;
105
extern calculus *check_tag_etc_calculus PROTO_S ( ( calculus *, unsigned, unsigned, CONST_S char *, int ) ) ;
106
#define CHECK_NULL( P )\
107
    ( check_null_calculus ( ( P ), __FILE__, __LINE__ ) )
108
#define CHECK_TAG( P, N )\
109
    ( check_tag_calculus ( ( P ), ( unsigned ) ( N ), __FILE__, __LINE__ ) )
110
#define CHECK_TAG_ETC( P, L, U )\
111
    ( check_tag_etc_calculus ( ( P ), ( unsigned ) ( L ), ( unsigned ) ( U ), __FILE__, __LINE__ ) )
112
#else
113
#define CHECK_NULL( P )			( P )
114
#define CHECK_TAG( P, N )		( P )
115
#define CHECK_TAG_ETC( P, L, U )	( P )
116
#endif
117
 
118
 
119
/* Enumeration definitions */
120
 
121
 
122
 
123
/* Union type definitions */
124
 
125
typedef calculus *TYPE ;
126
typedef calculus *COMMAND ;
127
 
128
 
129
/* Structure declarations */
130
 
131
typedef struct alg_tag ALGEBRA_DEFN ;
132
typedef struct cid_tag CLASS_ID ;
133
typedef struct prim_tag PRIMITIVE ;
134
typedef struct ec_tag ECONST ;
135
typedef struct en_tag ENUM ;
136
typedef struct ident_tag IDENTITY ;
137
typedef struct cmp_tag COMPONENT ;
138
typedef struct str_tag STRUCTURE ;
139
typedef struct fld_tag FIELD ;
140
typedef struct arg_tag ARGUMENT ;
141
typedef struct map_tag MAP ;
142
typedef struct un_tag UNION ;
143
 
144
 
145
/* Identity type definitions */
146
 
147
typedef string name_string ;
148
typedef int zero_int ;
149
typedef PTR ( int ) int_P ;
150
typedef PTR ( number ) number_P ;
151
typedef PTR ( string ) string_P ;
152
typedef PTR ( ARGUMENT ) ARGUMENT_P ;
153
typedef PTR ( CLASS_ID ) CLASS_ID_P ;
154
typedef PTR ( CLASS_ID_P ) CLASS_ID_P_P ;
155
typedef PTR ( COMPONENT ) COMPONENT_P ;
156
typedef PTR ( ECONST ) ECONST_P ;
157
typedef PTR ( ENUM ) ENUM_P ;
158
typedef PTR ( FIELD ) FIELD_P ;
159
typedef PTR ( IDENTITY ) IDENTITY_P ;
160
typedef PTR ( MAP ) MAP_P ;
161
typedef PTR ( PRIMITIVE ) PRIMITIVE_P ;
162
typedef PTR ( STRUCTURE ) STRUCTURE_P ;
163
typedef PTR ( TYPE ) TYPE_P ;
164
typedef PTR ( TYPE_P ) TYPE_P_P ;
165
typedef PTR ( UNION ) UNION_P ;
166
 
167
 
168
/* Structure definitions */
169
 
170
#ifndef calculus_STRUCT_DEFINED
171
#define calculus_STRUCT_DEFINED
172
 
173
struct alg_tag {
174
    string name ;
175
    int major_no ;
176
    int minor_no ;
177
    LIST ( PRIMITIVE_P ) primitives ;
178
    LIST ( IDENTITY_P ) identities ;
179
    LIST ( ENUM_P ) enumerations ;
180
    LIST ( STRUCTURE_P ) structures ;
181
    LIST ( UNION_P ) unions ;
182
    LIST ( TYPE_P ) types ;
183
} ;
184
 
185
struct cid_tag {
186
    string name ;
187
    string name_aux ;
188
    int flag ;
189
    name_string file ;
190
    int line ;
191
} ;
192
 
193
struct prim_tag {
194
    CLASS_ID_P id ;
195
    string defn ;
196
} ;
197
 
198
struct ec_tag {
199
    string name ;
200
    number value ;
201
} ;
202
 
203
struct en_tag {
204
    CLASS_ID_P id ;
205
    LIST ( ECONST_P ) consts ;
206
    number order ;
207
    int lists ;
208
} ;
209
 
210
struct ident_tag {
211
    CLASS_ID_P id ;
212
    TYPE_P defn ;
213
} ;
214
 
215
struct cmp_tag {
216
    string name ;
217
    TYPE_P type ;
218
    string value ;
219
} ;
220
 
221
struct str_tag {
222
    CLASS_ID_P id ;
223
    STRUCTURE_P base ;
224
    LIST ( COMPONENT_P ) defn ;
225
    zero_int output ;
226
} ;
227
 
228
struct fld_tag {
229
    string name ;
230
    int tag ;
231
    int flag ;
232
    int set ;
233
    FIELD_P base ;
234
    LIST ( COMPONENT_P ) defn ;
235
} ;
236
 
237
struct arg_tag {
238
    string name ;
239
    TYPE_P type ;
240
} ;
241
 
242
struct map_tag {
243
    string name ;
244
    int flag ;
245
    TYPE_P ret_type ;
246
    LIST ( ARGUMENT_P ) args ;
247
} ;
248
 
249
struct un_tag {
250
    CLASS_ID_P id ;
251
    UNION_P base ;
252
    LIST ( COMPONENT_P ) s_defn ;
253
    LIST ( FIELD_P ) u_defn ;
254
    LIST ( MAP_P ) map ;
255
    int no_fields ;
256
} ;
257
 
258
#endif /* calculus_STRUCT_DEFINED */
259
 
260
 
261
/* Function declarations */
262
 
263
extern calculus *gen_calculus PROTO_S ( ( unsigned ) ) ;
264
extern void destroy_calculus PROTO_S ( ( calculus *, unsigned ) ) ;
265
extern void dummy_destroy_calculus PROTO_S ( ( calculus *, unsigned ) ) ;
266
extern void destroy_calculus_list PROTO_S ( ( calculus *, unsigned ) ) ;
267
extern calculus *append_calculus_list PROTO_S ( ( calculus *, calculus * ) ) ;
268
extern calculus *end_calculus_list PROTO_S ( ( calculus * ) ) ;
269
extern unsigned length_calculus_list PROTO_S ( ( calculus * ) ) ;
270
extern calculus *reverse_calculus_list PROTO_S ( ( calculus * ) ) ;
271
#ifdef calculus_IO_ROUTINES
272
extern unsigned crt_calculus_alias ;
273
extern void set_calculus_alias PROTO_S ( ( calculus *, unsigned ) ) ;
274
extern calculus *find_calculus_alias PROTO_S ( ( unsigned ) ) ;
275
extern void clear_calculus_alias PROTO_S ( ( void ) ) ;
276
#endif
277
 
278
 
279
/* Run-time type information */
280
 
281
#ifndef GEN_calculus
282
#define GEN_calculus( A, B )		gen_calculus ( ( unsigned ) ( A ) )
283
#endif
284
#define TYPEID_ptr			( ( unsigned ) 0 )
285
#define TYPEID_list			( ( unsigned ) 1 )
286
#define TYPEID_stack			( ( unsigned ) 2 )
287
#define TYPEID_type			( ( unsigned ) 3 )
288
#define TYPEID_cmd			( ( unsigned ) 4 )
289
 
290
 
291
/* Definitions for pointers */
292
 
293
#define STEP_ptr( A, B )		( CHECK_NULL ( A ) + B )
294
#define SIZE_ptr( A )			1
295
#define NULL_ptr( A )			( ( calculus * ) 0 )
296
#define IS_NULL_ptr( A )		( ( A ) == 0 )
297
#define EQ_ptr( A, B )			( ( A ) == ( B ) )
298
#define MAKE_ptr( A )			GEN_calculus ( ( A ), TYPEID_ptr )
299
#define DESTROY_ptr( A, B )		destroy_calculus ( ( A ), ( unsigned ) ( B ) )
300
#define UNIQ_ptr( A )			GEN_calculus ( 1, TYPEID_ptr )
301
#define DESTROY_UNIQ_ptr( A )		destroy_calculus ( ( A ), ( unsigned ) 1 )
302
#ifdef calculus_IO_ROUTINES
303
#define VOIDSTAR_ptr( A )		( ( void * ) ( A ) )
304
#endif
305
 
306
#define COPY_ptr( A, B )		( CHECK_NULL ( A )->ag_ptr = ( B ) )
307
#define DEREF_ptr( A )			( CHECK_NULL ( A )->ag_ptr )
308
#define CONS_ptr( A, B, C )\
309
    {\
310
	calculus *x0_ = GEN_calculus ( 2, TYPEID_list ) ;\
311
	x0_ [1].ag_ptr = ( A ) ;\
312
	x0_->ag_ptr = ( B ) ;\
313
	( C ) = x0_ ;\
314
    }
315
 
316
#define UN_CONS_ptr( A, B, C )\
317
    {\
318
	calculus *x1_ = CHECK_NULL ( C ) ;\
319
	( A ) = x1_ [1].ag_ptr ;\
320
	( B ) = x1_->ag_ptr ;\
321
    }
322
 
323
#define DESTROY_CONS_ptr( D, A, B, C )\
324
    {\
325
	calculus *x2_ = CHECK_NULL ( C ) ;\
326
	( A ) = x2_ [1].ag_ptr ;\
327
	( B ) = x2_->ag_ptr ;\
328
	( D ) ( x2_, ( unsigned ) 2 ) ;\
329
    }
330
 
331
#define PUSH_ptr( A, B )\
332
    {\
333
	calculus **r3_ = &( B ) ;\
334
	calculus *x3_ = GEN_calculus ( 2, TYPEID_stack ) ;\
335
	x3_ [1].ag_ptr = ( A ) ;\
336
	x3_->ag_ptr = *r3_ ;\
337
	*r3_ = x3_ ;\
338
    }
339
 
340
#define POP_ptr( A, B )\
341
    {\
342
	calculus **r4_ = &( B ) ;\
343
	calculus *x4_ = CHECK_NULL ( *r4_ ) ;\
344
	( A ) = x4_ [1].ag_ptr ;\
345
	*r4_ = x4_->ag_ptr ;\
346
	destroy_calculus ( x4_, ( unsigned ) 2 ) ;\
347
    }
348
 
349
 
350
/* Definitions for lists */
351
 
352
#define HEAD_list( A )			( CHECK_NULL ( A ) + 1 )
353
#define PTR_TAIL_list( A )		( CHECK_NULL ( A ) )
354
#define TAIL_list( A )			( CHECK_NULL ( A )->ag_ptr )
355
#define LENGTH_list( A )		length_calculus_list ( ( A ) )
356
#define END_list( A )			end_calculus_list ( ( A ) )
357
#define REVERSE_list( A )		reverse_calculus_list ( ( A ) )
358
#define APPEND_list( A, B )		append_calculus_list ( ( A ), ( B ) )
359
 
360
#define SIZE_list( A )			1
361
#define NULL_list( A )			( ( calculus * ) 0 )
362
#define IS_NULL_list( A )		( ( A ) == 0 )
363
#define EQ_list( A, B )			( ( A ) == ( B ) )
364
#define UNIQ_list( A )			GEN_calculus ( 1, TYPEID_list )
365
#define DESTROY_UNIQ_list( A )		destroy_calculus ( ( A ), ( unsigned ) 1 )
366
#ifdef calculus_IO_ROUTINES
367
#define VOIDSTAR_list( A )		( ( void * ) ( A ) )
368
#endif
369
 
370
#define DESTROY_list( A, B )\
371
    {\
372
	destroy_calculus_list ( ( A ), ( unsigned ) ( B ) ) ;\
373
    }
374
 
375
#define COPY_list( A, B )		( CHECK_NULL ( A )->ag_ptr = ( B ) )
376
#define DEREF_list( A )			( CHECK_NULL ( A )->ag_ptr )
377
#define CONS_list( A, B, C )\
378
    {\
379
	calculus *x5_ = GEN_calculus ( 2, TYPEID_list ) ;\
380
	x5_ [1].ag_ptr = ( A ) ;\
381
	x5_->ag_ptr = ( B ) ;\
382
	( C ) = x5_ ;\
383
    }
384
 
385
#define UN_CONS_list( A, B, C )\
386
    {\
387
	calculus *x6_ = CHECK_NULL ( C ) ;\
388
	( A ) = x6_ [1].ag_ptr ;\
389
	( B ) = x6_->ag_ptr ;\
390
    }
391
 
392
#define DESTROY_CONS_list( D, A, B, C )\
393
    {\
394
	calculus *x7_ = CHECK_NULL ( C ) ;\
395
	( A ) = x7_ [1].ag_ptr ;\
396
	( B ) = x7_->ag_ptr ;\
397
	( D ) ( x7_, ( unsigned ) 2 ) ;\
398
    }
399
 
400
#define PUSH_list( A, B )\
401
    {\
402
	calculus **r8_ = &( B ) ;\
403
	calculus *x8_ = GEN_calculus ( 2, TYPEID_stack ) ;\
404
	x8_ [1].ag_ptr = ( A ) ;\
405
	x8_->ag_ptr = *r8_ ;\
406
	*r8_ = x8_ ;\
407
    }
408
 
409
#define POP_list( A, B )\
410
    {\
411
	calculus **r9_ = &( B ) ;\
412
	calculus *x9_ = CHECK_NULL ( *r9_ ) ;\
413
	( A ) = x9_ [1].ag_ptr ;\
414
	*r9_ = x9_->ag_ptr ;\
415
	destroy_calculus ( x9_, ( unsigned ) 2 ) ;\
416
    }
417
 
418
 
419
/* Definitions for stacks */
420
 
421
#define SIZE_stack( A )			1
422
#define NULL_stack( A )			( ( calculus * ) 0 )
423
#define IS_NULL_stack( A )		( ( A ) == 0 )
424
#define STACK_list( A )			( A )
425
#define LIST_stack( A )			( A )
426
 
427
#define COPY_stack( A, B )		( CHECK_NULL ( A )->ag_ptr = ( B ) )
428
#define DEREF_stack( A )		( CHECK_NULL ( A )->ag_ptr )
429
#define CONS_stack( A, B, C )\
430
    {\
431
	calculus *x10_ = GEN_calculus ( 2, TYPEID_list ) ;\
432
	x10_ [1].ag_ptr = ( A ) ;\
433
	x10_->ag_ptr = ( B ) ;\
434
	( C ) = x10_ ;\
435
    }
436
 
437
#define UN_CONS_stack( A, B, C )\
438
    {\
439
	calculus *x11_ = CHECK_NULL ( C ) ;\
440
	( A ) = x11_ [1].ag_ptr ;\
441
	( B ) = x11_->ag_ptr ;\
442
    }
443
 
444
#define DESTROY_CONS_stack( D, A, B, C )\
445
    {\
446
	calculus *x12_ = CHECK_NULL ( C ) ;\
447
	( A ) = x12_ [1].ag_ptr ;\
448
	( B ) = x12_->ag_ptr ;\
449
	( D ) ( x12_, ( unsigned ) 2 ) ;\
450
    }
451
 
452
#define PUSH_stack( A, B )\
453
    {\
454
	calculus **r13_ = &( B ) ;\
455
	calculus *x13_ = GEN_calculus ( 2, TYPEID_stack ) ;\
456
	x13_ [1].ag_ptr = ( A ) ;\
457
	x13_->ag_ptr = *r13_ ;\
458
	*r13_ = x13_ ;\
459
    }
460
 
461
#define POP_stack( A, B )\
462
    {\
463
	calculus **r14_ = &( B ) ;\
464
	calculus *x14_ = CHECK_NULL ( *r14_ ) ;\
465
	( A ) = x14_ [1].ag_ptr ;\
466
	*r14_ = x14_->ag_ptr ;\
467
	destroy_calculus ( x14_, ( unsigned ) 2 ) ;\
468
    }
469
 
470
 
471
/* Definitions for sizes */
472
 
473
#define SCALE( A, B )			( ( A ) * ( int ) ( B ) )
474
 
475
 
476
/* Definitions for primitive int */
477
 
478
#define SIZE_int			1
479
 
480
#define COPY_int( A, B )		( CHECK_NULL ( A )->ag_prim_int = ( B ) )
481
#define DEREF_int( A )			( CHECK_NULL ( A )->ag_prim_int )
482
#define CONS_int( A, B, C )\
483
    {\
484
	calculus *x15_ = GEN_calculus ( 2, TYPEID_list ) ;\
485
	COPY_int ( x15_ + 1, ( A ) ) ;\
486
	x15_->ag_ptr = ( B ) ;\
487
	( C ) = x15_ ;\
488
    }
489
 
490
#define UN_CONS_int( A, B, C )\
491
    {\
492
	calculus *x16_ = CHECK_NULL ( C ) ;\
493
	( A ) = DEREF_int ( x16_ + 1 ) ;\
494
	( B ) = x16_->ag_ptr ;\
495
    }
496
 
497
#define DESTROY_CONS_int( D, A, B, C )\
498
    {\
499
	calculus *x17_ = CHECK_NULL ( C ) ;\
500
	( A ) = DEREF_int ( x17_ + 1 ) ;\
501
	( B ) = x17_->ag_ptr ;\
502
	( D ) ( x17_, ( unsigned ) 2 ) ;\
503
    }
504
 
505
#define PUSH_int( A, B )\
506
    {\
507
	calculus **r18_ = &( B ) ;\
508
	calculus *x18_ = GEN_calculus ( 2, TYPEID_stack ) ;\
509
	COPY_int ( x18_ + 1, ( A ) ) ;\
510
	x18_->ag_ptr = *r18_ ;\
511
	*r18_ = x18_ ;\
512
    }
513
 
514
#define POP_int( A, B )\
515
    {\
516
	calculus **r19_ = &( B ) ;\
517
	calculus *x19_ = CHECK_NULL ( *r19_ ) ;\
518
	( A ) = DEREF_int ( x19_ + 1 ) ;\
519
	*r19_ = x19_->ag_ptr ;\
520
	destroy_calculus ( x19_, ( unsigned ) 2 ) ;\
521
    }
522
 
523
 
524
/* Definitions for primitive number */
525
 
526
#define SIZE_number			1
527
 
528
#define COPY_number( A, B )		( CHECK_NULL ( A )->ag_prim_number = ( B ) )
529
#define DEREF_number( A )		( CHECK_NULL ( A )->ag_prim_number )
530
#define CONS_number( A, B, C )\
531
    {\
532
	calculus *x20_ = GEN_calculus ( 2, TYPEID_list ) ;\
533
	COPY_number ( x20_ + 1, ( A ) ) ;\
534
	x20_->ag_ptr = ( B ) ;\
535
	( C ) = x20_ ;\
536
    }
537
 
538
#define UN_CONS_number( A, B, C )\
539
    {\
540
	calculus *x21_ = CHECK_NULL ( C ) ;\
541
	( A ) = DEREF_number ( x21_ + 1 ) ;\
542
	( B ) = x21_->ag_ptr ;\
543
    }
544
 
545
#define DESTROY_CONS_number( D, A, B, C )\
546
    {\
547
	calculus *x22_ = CHECK_NULL ( C ) ;\
548
	( A ) = DEREF_number ( x22_ + 1 ) ;\
549
	( B ) = x22_->ag_ptr ;\
550
	( D ) ( x22_, ( unsigned ) 2 ) ;\
551
    }
552
 
553
#define PUSH_number( A, B )\
554
    {\
555
	calculus **r23_ = &( B ) ;\
556
	calculus *x23_ = GEN_calculus ( 2, TYPEID_stack ) ;\
557
	COPY_number ( x23_ + 1, ( A ) ) ;\
558
	x23_->ag_ptr = *r23_ ;\
559
	*r23_ = x23_ ;\
560
    }
561
 
562
#define POP_number( A, B )\
563
    {\
564
	calculus **r24_ = &( B ) ;\
565
	calculus *x24_ = CHECK_NULL ( *r24_ ) ;\
566
	( A ) = DEREF_number ( x24_ + 1 ) ;\
567
	*r24_ = x24_->ag_ptr ;\
568
	destroy_calculus ( x24_, ( unsigned ) 2 ) ;\
569
    }
570
 
571
 
572
/* Definitions for primitive string */
573
 
574
#define SIZE_string			1
575
 
576
#define COPY_string( A, B )		( CHECK_NULL ( A )->ag_prim_string = ( B ) )
577
#define DEREF_string( A )		( CHECK_NULL ( A )->ag_prim_string )
578
#define CONS_string( A, B, C )\
579
    {\
580
	calculus *x25_ = GEN_calculus ( 2, TYPEID_list ) ;\
581
	COPY_string ( x25_ + 1, ( A ) ) ;\
582
	x25_->ag_ptr = ( B ) ;\
583
	( C ) = x25_ ;\
584
    }
585
 
586
#define UN_CONS_string( A, B, C )\
587
    {\
588
	calculus *x26_ = CHECK_NULL ( C ) ;\
589
	( A ) = DEREF_string ( x26_ + 1 ) ;\
590
	( B ) = x26_->ag_ptr ;\
591
    }
592
 
593
#define DESTROY_CONS_string( D, A, B, C )\
594
    {\
595
	calculus *x27_ = CHECK_NULL ( C ) ;\
596
	( A ) = DEREF_string ( x27_ + 1 ) ;\
597
	( B ) = x27_->ag_ptr ;\
598
	( D ) ( x27_, ( unsigned ) 2 ) ;\
599
    }
600
 
601
#define PUSH_string( A, B )\
602
    {\
603
	calculus **r28_ = &( B ) ;\
604
	calculus *x28_ = GEN_calculus ( 2, TYPEID_stack ) ;\
605
	COPY_string ( x28_ + 1, ( A ) ) ;\
606
	x28_->ag_ptr = *r28_ ;\
607
	*r28_ = x28_ ;\
608
    }
609
 
610
#define POP_string( A, B )\
611
    {\
612
	calculus **r29_ = &( B ) ;\
613
	calculus *x29_ = CHECK_NULL ( *r29_ ) ;\
614
	( A ) = DEREF_string ( x29_ + 1 ) ;\
615
	*r29_ = x29_->ag_ptr ;\
616
	destroy_calculus ( x29_, ( unsigned ) 2 ) ;\
617
    }
618
 
619
 
620
/* Definitions for structure ALGEBRA_DEFN */
621
 
622
#define alg_name( P )			( ( P ) + 0 )
623
#define alg_major_no( P )		( ( P ) + 1 )
624
#define alg_minor_no( P )		( ( P ) + 2 )
625
#define alg_primitives( P )		( ( P ) + 3 )
626
#define alg_identities( P )		( ( P ) + 4 )
627
#define alg_enumerations( P )		( ( P ) + 5 )
628
#define alg_structures( P )		( ( P ) + 6 )
629
#define alg_unions( P )			( ( P ) + 7 )
630
#define alg_types( P )			( ( P ) + 8 )
631
#define SIZE_alg			9
632
 
633
#define COPY_alg( A, B )\
634
    {\
635
	calculus *x30_ = CHECK_NULL ( A ) ;\
636
	ALGEBRA_DEFN y30_ ;\
637
	y30_ = ( B ) ;\
638
	COPY_string ( x30_ + 0, y30_.name ) ;\
639
	COPY_int ( x30_ + 1, y30_.major_no ) ;\
640
	COPY_int ( x30_ + 2, y30_.minor_no ) ;\
641
	COPY_list ( x30_ + 3, y30_.primitives ) ;\
642
	COPY_list ( x30_ + 4, y30_.identities ) ;\
643
	COPY_list ( x30_ + 5, y30_.enumerations ) ;\
644
	COPY_list ( x30_ + 6, y30_.structures ) ;\
645
	COPY_list ( x30_ + 7, y30_.unions ) ;\
646
	COPY_list ( x30_ + 8, y30_.types ) ;\
647
    }
648
 
649
#define DEREF_alg( A, B )\
650
    {\
651
	calculus *x31_ = CHECK_NULL ( A ) ;\
652
	ALGEBRA_DEFN *y31_ = &( B ) ;\
653
	y31_->name = DEREF_string ( x31_ + 0 ) ;\
654
	y31_->major_no = DEREF_int ( x31_ + 1 ) ;\
655
	y31_->minor_no = DEREF_int ( x31_ + 2 ) ;\
656
	y31_->primitives = DEREF_list ( x31_ + 3 ) ;\
657
	y31_->identities = DEREF_list ( x31_ + 4 ) ;\
658
	y31_->enumerations = DEREF_list ( x31_ + 5 ) ;\
659
	y31_->structures = DEREF_list ( x31_ + 6 ) ;\
660
	y31_->unions = DEREF_list ( x31_ + 7 ) ;\
661
	y31_->types = DEREF_list ( x31_ + 8 ) ;\
662
    }
663
 
664
#define MAKE_alg( name_, major_no_, minor_no_, primitives_, identities_, enumerations_, structures_, unions_, types_, alg_ )\
665
    {\
666
	calculus *x32_ = CHECK_NULL ( alg_ ) ;\
667
	COPY_string ( x32_ + 0, ( name_ ) ) ;\
668
	COPY_int ( x32_ + 1, ( major_no_ ) ) ;\
669
	COPY_int ( x32_ + 2, ( minor_no_ ) ) ;\
670
	COPY_list ( x32_ + 3, ( primitives_ ) ) ;\
671
	COPY_list ( x32_ + 4, ( identities_ ) ) ;\
672
	COPY_list ( x32_ + 5, ( enumerations_ ) ) ;\
673
	COPY_list ( x32_ + 6, ( structures_ ) ) ;\
674
	COPY_list ( x32_ + 7, ( unions_ ) ) ;\
675
	COPY_list ( x32_ + 8, ( types_ ) ) ;\
676
    }
677
 
678
#define CONS_alg( A, B, C )\
679
    {\
680
	calculus *x33_ = GEN_calculus ( 10, TYPEID_list ) ;\
681
	COPY_alg ( x33_ + 1, ( A ) ) ;\
682
	x33_->ag_ptr = ( B ) ;\
683
	( C ) = x33_ ;\
684
    }
685
 
686
#define UN_CONS_alg( A, B, C )\
687
    {\
688
	calculus *x34_ = CHECK_NULL ( C ) ;\
689
	DEREF_alg ( x34_ + 1, ( A ) ) ;\
690
	( B ) = x34_->ag_ptr ;\
691
    }
692
 
693
#define DESTROY_CONS_alg( D, A, B, C )\
694
    {\
695
	calculus *x35_ = CHECK_NULL ( C ) ;\
696
	DEREF_alg ( x35_ + 1, ( A ) ) ;\
697
	( B ) = x35_->ag_ptr ;\
698
	( D ) ( x35_, ( unsigned ) 10 ) ;\
699
    }
700
 
701
#define PUSH_alg( A, B )\
702
    {\
703
	calculus **r36_ = &( B ) ;\
704
	calculus *x36_ = GEN_calculus ( 10, TYPEID_stack ) ;\
705
	COPY_alg ( x36_ + 1, ( A ) ) ;\
706
	x36_->ag_ptr = *r36_ ;\
707
	*r36_ = x36_ ;\
708
    }
709
 
710
#define POP_alg( A, B )\
711
    {\
712
	calculus **r37_ = &( B ) ;\
713
	calculus *x37_ = CHECK_NULL ( *r37_ ) ;\
714
	DEREF_alg ( x37_ + 1, ( A ) ) ;\
715
	*r37_ = x37_->ag_ptr ;\
716
	destroy_calculus ( x37_, ( unsigned ) 10 ) ;\
717
    }
718
 
719
 
720
/* Definitions for structure CLASS_ID */
721
 
722
#define cid_name( P )			( ( P ) + 0 )
723
#define cid_name_aux( P )		( ( P ) + 1 )
724
#define cid_flag( P )			( ( P ) + 2 )
725
#define cid_file( P )			( ( P ) + 3 )
726
#define cid_line( P )			( ( P ) + 4 )
727
#define SIZE_cid			5
728
 
729
#define COPY_cid( A, B )\
730
    {\
731
	calculus *x38_ = CHECK_NULL ( A ) ;\
732
	CLASS_ID y38_ ;\
733
	y38_ = ( B ) ;\
734
	COPY_string ( x38_ + 0, y38_.name ) ;\
735
	COPY_string ( x38_ + 1, y38_.name_aux ) ;\
736
	COPY_int ( x38_ + 2, y38_.flag ) ;\
737
	COPY_string ( x38_ + 3, y38_.file ) ;\
738
	COPY_int ( x38_ + 4, y38_.line ) ;\
739
    }
740
 
741
#define DEREF_cid( A, B )\
742
    {\
743
	calculus *x39_ = CHECK_NULL ( A ) ;\
744
	CLASS_ID *y39_ = &( B ) ;\
745
	y39_->name = DEREF_string ( x39_ + 0 ) ;\
746
	y39_->name_aux = DEREF_string ( x39_ + 1 ) ;\
747
	y39_->flag = DEREF_int ( x39_ + 2 ) ;\
748
	y39_->file = DEREF_string ( x39_ + 3 ) ;\
749
	y39_->line = DEREF_int ( x39_ + 4 ) ;\
750
    }
751
 
752
#define MAKE_cid( name_, name_aux_, flag_, file_, line_, cid_ )\
753
    {\
754
	calculus *x40_ = CHECK_NULL ( cid_ ) ;\
755
	COPY_string ( x40_ + 0, ( name_ ) ) ;\
756
	COPY_string ( x40_ + 1, ( name_aux_ ) ) ;\
757
	COPY_int ( x40_ + 2, ( flag_ ) ) ;\
758
	COPY_string ( x40_ + 3, ( file_ ) ) ;\
759
	COPY_int ( x40_ + 4, ( line_ ) ) ;\
760
    }
761
 
762
#define CONS_cid( A, B, C )\
763
    {\
764
	calculus *x41_ = GEN_calculus ( 6, TYPEID_list ) ;\
765
	COPY_cid ( x41_ + 1, ( A ) ) ;\
766
	x41_->ag_ptr = ( B ) ;\
767
	( C ) = x41_ ;\
768
    }
769
 
770
#define UN_CONS_cid( A, B, C )\
771
    {\
772
	calculus *x42_ = CHECK_NULL ( C ) ;\
773
	DEREF_cid ( x42_ + 1, ( A ) ) ;\
774
	( B ) = x42_->ag_ptr ;\
775
    }
776
 
777
#define DESTROY_CONS_cid( D, A, B, C )\
778
    {\
779
	calculus *x43_ = CHECK_NULL ( C ) ;\
780
	DEREF_cid ( x43_ + 1, ( A ) ) ;\
781
	( B ) = x43_->ag_ptr ;\
782
	( D ) ( x43_, ( unsigned ) 6 ) ;\
783
    }
784
 
785
#define PUSH_cid( A, B )\
786
    {\
787
	calculus **r44_ = &( B ) ;\
788
	calculus *x44_ = GEN_calculus ( 6, TYPEID_stack ) ;\
789
	COPY_cid ( x44_ + 1, ( A ) ) ;\
790
	x44_->ag_ptr = *r44_ ;\
791
	*r44_ = x44_ ;\
792
    }
793
 
794
#define POP_cid( A, B )\
795
    {\
796
	calculus **r45_ = &( B ) ;\
797
	calculus *x45_ = CHECK_NULL ( *r45_ ) ;\
798
	DEREF_cid ( x45_ + 1, ( A ) ) ;\
799
	*r45_ = x45_->ag_ptr ;\
800
	destroy_calculus ( x45_, ( unsigned ) 6 ) ;\
801
    }
802
 
803
 
804
/* Definitions for structure PRIMITIVE */
805
 
806
#define prim_id( P )			( ( P ) + 0 )
807
#define prim_defn( P )			( ( P ) + 1 )
808
#define SIZE_prim			2
809
 
810
#define COPY_prim( A, B )\
811
    {\
812
	calculus *x46_ = CHECK_NULL ( A ) ;\
813
	PRIMITIVE y46_ ;\
814
	y46_ = ( B ) ;\
815
	COPY_ptr ( x46_ + 0, y46_.id ) ;\
816
	COPY_string ( x46_ + 1, y46_.defn ) ;\
817
    }
818
 
819
#define DEREF_prim( A, B )\
820
    {\
821
	calculus *x47_ = CHECK_NULL ( A ) ;\
822
	PRIMITIVE *y47_ = &( B ) ;\
823
	y47_->id = DEREF_ptr ( x47_ + 0 ) ;\
824
	y47_->defn = DEREF_string ( x47_ + 1 ) ;\
825
    }
826
 
827
#define MAKE_prim( id_, defn_, prim_ )\
828
    {\
829
	calculus *x48_ = CHECK_NULL ( prim_ ) ;\
830
	COPY_ptr ( x48_ + 0, ( id_ ) ) ;\
831
	COPY_string ( x48_ + 1, ( defn_ ) ) ;\
832
    }
833
 
834
#define CONS_prim( A, B, C )\
835
    {\
836
	calculus *x49_ = GEN_calculus ( 3, TYPEID_list ) ;\
837
	COPY_prim ( x49_ + 1, ( A ) ) ;\
838
	x49_->ag_ptr = ( B ) ;\
839
	( C ) = x49_ ;\
840
    }
841
 
842
#define UN_CONS_prim( A, B, C )\
843
    {\
844
	calculus *x50_ = CHECK_NULL ( C ) ;\
845
	DEREF_prim ( x50_ + 1, ( A ) ) ;\
846
	( B ) = x50_->ag_ptr ;\
847
    }
848
 
849
#define DESTROY_CONS_prim( D, A, B, C )\
850
    {\
851
	calculus *x51_ = CHECK_NULL ( C ) ;\
852
	DEREF_prim ( x51_ + 1, ( A ) ) ;\
853
	( B ) = x51_->ag_ptr ;\
854
	( D ) ( x51_, ( unsigned ) 3 ) ;\
855
    }
856
 
857
#define PUSH_prim( A, B )\
858
    {\
859
	calculus **r52_ = &( B ) ;\
860
	calculus *x52_ = GEN_calculus ( 3, TYPEID_stack ) ;\
861
	COPY_prim ( x52_ + 1, ( A ) ) ;\
862
	x52_->ag_ptr = *r52_ ;\
863
	*r52_ = x52_ ;\
864
    }
865
 
866
#define POP_prim( A, B )\
867
    {\
868
	calculus **r53_ = &( B ) ;\
869
	calculus *x53_ = CHECK_NULL ( *r53_ ) ;\
870
	DEREF_prim ( x53_ + 1, ( A ) ) ;\
871
	*r53_ = x53_->ag_ptr ;\
872
	destroy_calculus ( x53_, ( unsigned ) 3 ) ;\
873
    }
874
 
875
 
876
/* Definitions for structure ECONST */
877
 
878
#define ec_name( P )			( ( P ) + 0 )
879
#define ec_value( P )			( ( P ) + 1 )
880
#define SIZE_ec				2
881
 
882
#define COPY_ec( A, B )\
883
    {\
884
	calculus *x54_ = CHECK_NULL ( A ) ;\
885
	ECONST y54_ ;\
886
	y54_ = ( B ) ;\
887
	COPY_string ( x54_ + 0, y54_.name ) ;\
888
	COPY_number ( x54_ + 1, y54_.value ) ;\
889
    }
890
 
891
#define DEREF_ec( A, B )\
892
    {\
893
	calculus *x55_ = CHECK_NULL ( A ) ;\
894
	ECONST *y55_ = &( B ) ;\
895
	y55_->name = DEREF_string ( x55_ + 0 ) ;\
896
	y55_->value = DEREF_number ( x55_ + 1 ) ;\
897
    }
898
 
899
#define MAKE_ec( name_, value_, ec_ )\
900
    {\
901
	calculus *x56_ = CHECK_NULL ( ec_ ) ;\
902
	COPY_string ( x56_ + 0, ( name_ ) ) ;\
903
	COPY_number ( x56_ + 1, ( value_ ) ) ;\
904
    }
905
 
906
#define CONS_ec( A, B, C )\
907
    {\
908
	calculus *x57_ = GEN_calculus ( 3, TYPEID_list ) ;\
909
	COPY_ec ( x57_ + 1, ( A ) ) ;\
910
	x57_->ag_ptr = ( B ) ;\
911
	( C ) = x57_ ;\
912
    }
913
 
914
#define UN_CONS_ec( A, B, C )\
915
    {\
916
	calculus *x58_ = CHECK_NULL ( C ) ;\
917
	DEREF_ec ( x58_ + 1, ( A ) ) ;\
918
	( B ) = x58_->ag_ptr ;\
919
    }
920
 
921
#define DESTROY_CONS_ec( D, A, B, C )\
922
    {\
923
	calculus *x59_ = CHECK_NULL ( C ) ;\
924
	DEREF_ec ( x59_ + 1, ( A ) ) ;\
925
	( B ) = x59_->ag_ptr ;\
926
	( D ) ( x59_, ( unsigned ) 3 ) ;\
927
    }
928
 
929
#define PUSH_ec( A, B )\
930
    {\
931
	calculus **r60_ = &( B ) ;\
932
	calculus *x60_ = GEN_calculus ( 3, TYPEID_stack ) ;\
933
	COPY_ec ( x60_ + 1, ( A ) ) ;\
934
	x60_->ag_ptr = *r60_ ;\
935
	*r60_ = x60_ ;\
936
    }
937
 
938
#define POP_ec( A, B )\
939
    {\
940
	calculus **r61_ = &( B ) ;\
941
	calculus *x61_ = CHECK_NULL ( *r61_ ) ;\
942
	DEREF_ec ( x61_ + 1, ( A ) ) ;\
943
	*r61_ = x61_->ag_ptr ;\
944
	destroy_calculus ( x61_, ( unsigned ) 3 ) ;\
945
    }
946
 
947
 
948
/* Definitions for structure ENUM */
949
 
950
#define en_id( P )			( ( P ) + 0 )
951
#define en_consts( P )			( ( P ) + 1 )
952
#define en_order( P )			( ( P ) + 2 )
953
#define en_lists( P )			( ( P ) + 3 )
954
#define SIZE_en				4
955
 
956
#define COPY_en( A, B )\
957
    {\
958
	calculus *x62_ = CHECK_NULL ( A ) ;\
959
	ENUM y62_ ;\
960
	y62_ = ( B ) ;\
961
	COPY_ptr ( x62_ + 0, y62_.id ) ;\
962
	COPY_list ( x62_ + 1, y62_.consts ) ;\
963
	COPY_number ( x62_ + 2, y62_.order ) ;\
964
	COPY_int ( x62_ + 3, y62_.lists ) ;\
965
    }
966
 
967
#define DEREF_en( A, B )\
968
    {\
969
	calculus *x63_ = CHECK_NULL ( A ) ;\
970
	ENUM *y63_ = &( B ) ;\
971
	y63_->id = DEREF_ptr ( x63_ + 0 ) ;\
972
	y63_->consts = DEREF_list ( x63_ + 1 ) ;\
973
	y63_->order = DEREF_number ( x63_ + 2 ) ;\
974
	y63_->lists = DEREF_int ( x63_ + 3 ) ;\
975
    }
976
 
977
#define MAKE_en( id_, consts_, order_, lists_, en_ )\
978
    {\
979
	calculus *x64_ = CHECK_NULL ( en_ ) ;\
980
	COPY_ptr ( x64_ + 0, ( id_ ) ) ;\
981
	COPY_list ( x64_ + 1, ( consts_ ) ) ;\
982
	COPY_number ( x64_ + 2, ( order_ ) ) ;\
983
	COPY_int ( x64_ + 3, ( lists_ ) ) ;\
984
    }
985
 
986
#define CONS_en( A, B, C )\
987
    {\
988
	calculus *x65_ = GEN_calculus ( 5, TYPEID_list ) ;\
989
	COPY_en ( x65_ + 1, ( A ) ) ;\
990
	x65_->ag_ptr = ( B ) ;\
991
	( C ) = x65_ ;\
992
    }
993
 
994
#define UN_CONS_en( A, B, C )\
995
    {\
996
	calculus *x66_ = CHECK_NULL ( C ) ;\
997
	DEREF_en ( x66_ + 1, ( A ) ) ;\
998
	( B ) = x66_->ag_ptr ;\
999
    }
1000
 
1001
#define DESTROY_CONS_en( D, A, B, C )\
1002
    {\
1003
	calculus *x67_ = CHECK_NULL ( C ) ;\
1004
	DEREF_en ( x67_ + 1, ( A ) ) ;\
1005
	( B ) = x67_->ag_ptr ;\
1006
	( D ) ( x67_, ( unsigned ) 5 ) ;\
1007
    }
1008
 
1009
#define PUSH_en( A, B )\
1010
    {\
1011
	calculus **r68_ = &( B ) ;\
1012
	calculus *x68_ = GEN_calculus ( 5, TYPEID_stack ) ;\
1013
	COPY_en ( x68_ + 1, ( A ) ) ;\
1014
	x68_->ag_ptr = *r68_ ;\
1015
	*r68_ = x68_ ;\
1016
    }
1017
 
1018
#define POP_en( A, B )\
1019
    {\
1020
	calculus **r69_ = &( B ) ;\
1021
	calculus *x69_ = CHECK_NULL ( *r69_ ) ;\
1022
	DEREF_en ( x69_ + 1, ( A ) ) ;\
1023
	*r69_ = x69_->ag_ptr ;\
1024
	destroy_calculus ( x69_, ( unsigned ) 5 ) ;\
1025
    }
1026
 
1027
 
1028
/* Definitions for structure IDENTITY */
1029
 
1030
#define ident_id( P )			( ( P ) + 0 )
1031
#define ident_defn( P )			( ( P ) + 1 )
1032
#define SIZE_ident			2
1033
 
1034
#define COPY_ident( A, B )\
1035
    {\
1036
	calculus *x70_ = CHECK_NULL ( A ) ;\
1037
	IDENTITY y70_ ;\
1038
	y70_ = ( B ) ;\
1039
	COPY_ptr ( x70_ + 0, y70_.id ) ;\
1040
	COPY_ptr ( x70_ + 1, y70_.defn ) ;\
1041
    }
1042
 
1043
#define DEREF_ident( A, B )\
1044
    {\
1045
	calculus *x71_ = CHECK_NULL ( A ) ;\
1046
	IDENTITY *y71_ = &( B ) ;\
1047
	y71_->id = DEREF_ptr ( x71_ + 0 ) ;\
1048
	y71_->defn = DEREF_ptr ( x71_ + 1 ) ;\
1049
    }
1050
 
1051
#define MAKE_ident( id_, defn_, ident_ )\
1052
    {\
1053
	calculus *x72_ = CHECK_NULL ( ident_ ) ;\
1054
	COPY_ptr ( x72_ + 0, ( id_ ) ) ;\
1055
	COPY_ptr ( x72_ + 1, ( defn_ ) ) ;\
1056
    }
1057
 
1058
#define CONS_ident( A, B, C )\
1059
    {\
1060
	calculus *x73_ = GEN_calculus ( 3, TYPEID_list ) ;\
1061
	COPY_ident ( x73_ + 1, ( A ) ) ;\
1062
	x73_->ag_ptr = ( B ) ;\
1063
	( C ) = x73_ ;\
1064
    }
1065
 
1066
#define UN_CONS_ident( A, B, C )\
1067
    {\
1068
	calculus *x74_ = CHECK_NULL ( C ) ;\
1069
	DEREF_ident ( x74_ + 1, ( A ) ) ;\
1070
	( B ) = x74_->ag_ptr ;\
1071
    }
1072
 
1073
#define DESTROY_CONS_ident( D, A, B, C )\
1074
    {\
1075
	calculus *x75_ = CHECK_NULL ( C ) ;\
1076
	DEREF_ident ( x75_ + 1, ( A ) ) ;\
1077
	( B ) = x75_->ag_ptr ;\
1078
	( D ) ( x75_, ( unsigned ) 3 ) ;\
1079
    }
1080
 
1081
#define PUSH_ident( A, B )\
1082
    {\
1083
	calculus **r76_ = &( B ) ;\
1084
	calculus *x76_ = GEN_calculus ( 3, TYPEID_stack ) ;\
1085
	COPY_ident ( x76_ + 1, ( A ) ) ;\
1086
	x76_->ag_ptr = *r76_ ;\
1087
	*r76_ = x76_ ;\
1088
    }
1089
 
1090
#define POP_ident( A, B )\
1091
    {\
1092
	calculus **r77_ = &( B ) ;\
1093
	calculus *x77_ = CHECK_NULL ( *r77_ ) ;\
1094
	DEREF_ident ( x77_ + 1, ( A ) ) ;\
1095
	*r77_ = x77_->ag_ptr ;\
1096
	destroy_calculus ( x77_, ( unsigned ) 3 ) ;\
1097
    }
1098
 
1099
 
1100
/* Definitions for structure COMPONENT */
1101
 
1102
#define cmp_name( P )			( ( P ) + 0 )
1103
#define cmp_type( P )			( ( P ) + 1 )
1104
#define cmp_value( P )			( ( P ) + 2 )
1105
#define SIZE_cmp			3
1106
 
1107
#define COPY_cmp( A, B )\
1108
    {\
1109
	calculus *x78_ = CHECK_NULL ( A ) ;\
1110
	COMPONENT y78_ ;\
1111
	y78_ = ( B ) ;\
1112
	COPY_string ( x78_ + 0, y78_.name ) ;\
1113
	COPY_ptr ( x78_ + 1, y78_.type ) ;\
1114
	COPY_string ( x78_ + 2, y78_.value ) ;\
1115
    }
1116
 
1117
#define DEREF_cmp( A, B )\
1118
    {\
1119
	calculus *x79_ = CHECK_NULL ( A ) ;\
1120
	COMPONENT *y79_ = &( B ) ;\
1121
	y79_->name = DEREF_string ( x79_ + 0 ) ;\
1122
	y79_->type = DEREF_ptr ( x79_ + 1 ) ;\
1123
	y79_->value = DEREF_string ( x79_ + 2 ) ;\
1124
    }
1125
 
1126
#define MAKE_cmp( name_, type_, value_, cmp_ )\
1127
    {\
1128
	calculus *x80_ = CHECK_NULL ( cmp_ ) ;\
1129
	COPY_string ( x80_ + 0, ( name_ ) ) ;\
1130
	COPY_ptr ( x80_ + 1, ( type_ ) ) ;\
1131
	COPY_string ( x80_ + 2, ( value_ ) ) ;\
1132
    }
1133
 
1134
#define CONS_cmp( A, B, C )\
1135
    {\
1136
	calculus *x81_ = GEN_calculus ( 4, TYPEID_list ) ;\
1137
	COPY_cmp ( x81_ + 1, ( A ) ) ;\
1138
	x81_->ag_ptr = ( B ) ;\
1139
	( C ) = x81_ ;\
1140
    }
1141
 
1142
#define UN_CONS_cmp( A, B, C )\
1143
    {\
1144
	calculus *x82_ = CHECK_NULL ( C ) ;\
1145
	DEREF_cmp ( x82_ + 1, ( A ) ) ;\
1146
	( B ) = x82_->ag_ptr ;\
1147
    }
1148
 
1149
#define DESTROY_CONS_cmp( D, A, B, C )\
1150
    {\
1151
	calculus *x83_ = CHECK_NULL ( C ) ;\
1152
	DEREF_cmp ( x83_ + 1, ( A ) ) ;\
1153
	( B ) = x83_->ag_ptr ;\
1154
	( D ) ( x83_, ( unsigned ) 4 ) ;\
1155
    }
1156
 
1157
#define PUSH_cmp( A, B )\
1158
    {\
1159
	calculus **r84_ = &( B ) ;\
1160
	calculus *x84_ = GEN_calculus ( 4, TYPEID_stack ) ;\
1161
	COPY_cmp ( x84_ + 1, ( A ) ) ;\
1162
	x84_->ag_ptr = *r84_ ;\
1163
	*r84_ = x84_ ;\
1164
    }
1165
 
1166
#define POP_cmp( A, B )\
1167
    {\
1168
	calculus **r85_ = &( B ) ;\
1169
	calculus *x85_ = CHECK_NULL ( *r85_ ) ;\
1170
	DEREF_cmp ( x85_ + 1, ( A ) ) ;\
1171
	*r85_ = x85_->ag_ptr ;\
1172
	destroy_calculus ( x85_, ( unsigned ) 4 ) ;\
1173
    }
1174
 
1175
 
1176
/* Definitions for structure STRUCTURE */
1177
 
1178
#define str_id( P )			( ( P ) + 0 )
1179
#define str_base( P )			( ( P ) + 1 )
1180
#define str_defn( P )			( ( P ) + 2 )
1181
#define str_output( P )			( ( P ) + 3 )
1182
#define SIZE_str			4
1183
 
1184
#define COPY_str( A, B )\
1185
    {\
1186
	calculus *x86_ = CHECK_NULL ( A ) ;\
1187
	STRUCTURE y86_ ;\
1188
	y86_ = ( B ) ;\
1189
	COPY_ptr ( x86_ + 0, y86_.id ) ;\
1190
	COPY_ptr ( x86_ + 1, y86_.base ) ;\
1191
	COPY_list ( x86_ + 2, y86_.defn ) ;\
1192
	COPY_int ( x86_ + 3, y86_.output ) ;\
1193
    }
1194
 
1195
#define DEREF_str( A, B )\
1196
    {\
1197
	calculus *x87_ = CHECK_NULL ( A ) ;\
1198
	STRUCTURE *y87_ = &( B ) ;\
1199
	y87_->id = DEREF_ptr ( x87_ + 0 ) ;\
1200
	y87_->base = DEREF_ptr ( x87_ + 1 ) ;\
1201
	y87_->defn = DEREF_list ( x87_ + 2 ) ;\
1202
	y87_->output = DEREF_int ( x87_ + 3 ) ;\
1203
    }
1204
 
1205
#define MAKE_str( id_, base_, defn_, output_, str_ )\
1206
    {\
1207
	calculus *x88_ = CHECK_NULL ( str_ ) ;\
1208
	COPY_ptr ( x88_ + 0, ( id_ ) ) ;\
1209
	COPY_ptr ( x88_ + 1, ( base_ ) ) ;\
1210
	COPY_list ( x88_ + 2, ( defn_ ) ) ;\
1211
	COPY_int ( x88_ + 3, ( output_ ) ) ;\
1212
    }
1213
 
1214
#define CONS_str( A, B, C )\
1215
    {\
1216
	calculus *x89_ = GEN_calculus ( 5, TYPEID_list ) ;\
1217
	COPY_str ( x89_ + 1, ( A ) ) ;\
1218
	x89_->ag_ptr = ( B ) ;\
1219
	( C ) = x89_ ;\
1220
    }
1221
 
1222
#define UN_CONS_str( A, B, C )\
1223
    {\
1224
	calculus *x90_ = CHECK_NULL ( C ) ;\
1225
	DEREF_str ( x90_ + 1, ( A ) ) ;\
1226
	( B ) = x90_->ag_ptr ;\
1227
    }
1228
 
1229
#define DESTROY_CONS_str( D, A, B, C )\
1230
    {\
1231
	calculus *x91_ = CHECK_NULL ( C ) ;\
1232
	DEREF_str ( x91_ + 1, ( A ) ) ;\
1233
	( B ) = x91_->ag_ptr ;\
1234
	( D ) ( x91_, ( unsigned ) 5 ) ;\
1235
    }
1236
 
1237
#define PUSH_str( A, B )\
1238
    {\
1239
	calculus **r92_ = &( B ) ;\
1240
	calculus *x92_ = GEN_calculus ( 5, TYPEID_stack ) ;\
1241
	COPY_str ( x92_ + 1, ( A ) ) ;\
1242
	x92_->ag_ptr = *r92_ ;\
1243
	*r92_ = x92_ ;\
1244
    }
1245
 
1246
#define POP_str( A, B )\
1247
    {\
1248
	calculus **r93_ = &( B ) ;\
1249
	calculus *x93_ = CHECK_NULL ( *r93_ ) ;\
1250
	DEREF_str ( x93_ + 1, ( A ) ) ;\
1251
	*r93_ = x93_->ag_ptr ;\
1252
	destroy_calculus ( x93_, ( unsigned ) 5 ) ;\
1253
    }
1254
 
1255
 
1256
/* Definitions for structure FIELD */
1257
 
1258
#define fld_name( P )			( ( P ) + 0 )
1259
#define fld_tag( P )			( ( P ) + 1 )
1260
#define fld_flag( P )			( ( P ) + 2 )
1261
#define fld_set( P )			( ( P ) + 3 )
1262
#define fld_base( P )			( ( P ) + 4 )
1263
#define fld_defn( P )			( ( P ) + 5 )
1264
#define SIZE_fld			6
1265
 
1266
#define COPY_fld( A, B )\
1267
    {\
1268
	calculus *x94_ = CHECK_NULL ( A ) ;\
1269
	FIELD y94_ ;\
1270
	y94_ = ( B ) ;\
1271
	COPY_string ( x94_ + 0, y94_.name ) ;\
1272
	COPY_int ( x94_ + 1, y94_.tag ) ;\
1273
	COPY_int ( x94_ + 2, y94_.flag ) ;\
1274
	COPY_int ( x94_ + 3, y94_.set ) ;\
1275
	COPY_ptr ( x94_ + 4, y94_.base ) ;\
1276
	COPY_list ( x94_ + 5, y94_.defn ) ;\
1277
    }
1278
 
1279
#define DEREF_fld( A, B )\
1280
    {\
1281
	calculus *x95_ = CHECK_NULL ( A ) ;\
1282
	FIELD *y95_ = &( B ) ;\
1283
	y95_->name = DEREF_string ( x95_ + 0 ) ;\
1284
	y95_->tag = DEREF_int ( x95_ + 1 ) ;\
1285
	y95_->flag = DEREF_int ( x95_ + 2 ) ;\
1286
	y95_->set = DEREF_int ( x95_ + 3 ) ;\
1287
	y95_->base = DEREF_ptr ( x95_ + 4 ) ;\
1288
	y95_->defn = DEREF_list ( x95_ + 5 ) ;\
1289
    }
1290
 
1291
#define MAKE_fld( name_, tag_, flag_, set_, base_, defn_, fld_ )\
1292
    {\
1293
	calculus *x96_ = CHECK_NULL ( fld_ ) ;\
1294
	COPY_string ( x96_ + 0, ( name_ ) ) ;\
1295
	COPY_int ( x96_ + 1, ( tag_ ) ) ;\
1296
	COPY_int ( x96_ + 2, ( flag_ ) ) ;\
1297
	COPY_int ( x96_ + 3, ( set_ ) ) ;\
1298
	COPY_ptr ( x96_ + 4, ( base_ ) ) ;\
1299
	COPY_list ( x96_ + 5, ( defn_ ) ) ;\
1300
    }
1301
 
1302
#define CONS_fld( A, B, C )\
1303
    {\
1304
	calculus *x97_ = GEN_calculus ( 7, TYPEID_list ) ;\
1305
	COPY_fld ( x97_ + 1, ( A ) ) ;\
1306
	x97_->ag_ptr = ( B ) ;\
1307
	( C ) = x97_ ;\
1308
    }
1309
 
1310
#define UN_CONS_fld( A, B, C )\
1311
    {\
1312
	calculus *x98_ = CHECK_NULL ( C ) ;\
1313
	DEREF_fld ( x98_ + 1, ( A ) ) ;\
1314
	( B ) = x98_->ag_ptr ;\
1315
    }
1316
 
1317
#define DESTROY_CONS_fld( D, A, B, C )\
1318
    {\
1319
	calculus *x99_ = CHECK_NULL ( C ) ;\
1320
	DEREF_fld ( x99_ + 1, ( A ) ) ;\
1321
	( B ) = x99_->ag_ptr ;\
1322
	( D ) ( x99_, ( unsigned ) 7 ) ;\
1323
    }
1324
 
1325
#define PUSH_fld( A, B )\
1326
    {\
1327
	calculus **r100_ = &( B ) ;\
1328
	calculus *x100_ = GEN_calculus ( 7, TYPEID_stack ) ;\
1329
	COPY_fld ( x100_ + 1, ( A ) ) ;\
1330
	x100_->ag_ptr = *r100_ ;\
1331
	*r100_ = x100_ ;\
1332
    }
1333
 
1334
#define POP_fld( A, B )\
1335
    {\
1336
	calculus **r101_ = &( B ) ;\
1337
	calculus *x101_ = CHECK_NULL ( *r101_ ) ;\
1338
	DEREF_fld ( x101_ + 1, ( A ) ) ;\
1339
	*r101_ = x101_->ag_ptr ;\
1340
	destroy_calculus ( x101_, ( unsigned ) 7 ) ;\
1341
    }
1342
 
1343
 
1344
/* Definitions for structure ARGUMENT */
1345
 
1346
#define arg_name( P )			( ( P ) + 0 )
1347
#define arg_type( P )			( ( P ) + 1 )
1348
#define SIZE_arg			2
1349
 
1350
#define COPY_arg( A, B )\
1351
    {\
1352
	calculus *x102_ = CHECK_NULL ( A ) ;\
1353
	ARGUMENT y102_ ;\
1354
	y102_ = ( B ) ;\
1355
	COPY_string ( x102_ + 0, y102_.name ) ;\
1356
	COPY_ptr ( x102_ + 1, y102_.type ) ;\
1357
    }
1358
 
1359
#define DEREF_arg( A, B )\
1360
    {\
1361
	calculus *x103_ = CHECK_NULL ( A ) ;\
1362
	ARGUMENT *y103_ = &( B ) ;\
1363
	y103_->name = DEREF_string ( x103_ + 0 ) ;\
1364
	y103_->type = DEREF_ptr ( x103_ + 1 ) ;\
1365
    }
1366
 
1367
#define MAKE_arg( name_, type_, arg_ )\
1368
    {\
1369
	calculus *x104_ = CHECK_NULL ( arg_ ) ;\
1370
	COPY_string ( x104_ + 0, ( name_ ) ) ;\
1371
	COPY_ptr ( x104_ + 1, ( type_ ) ) ;\
1372
    }
1373
 
1374
#define CONS_arg( A, B, C )\
1375
    {\
1376
	calculus *x105_ = GEN_calculus ( 3, TYPEID_list ) ;\
1377
	COPY_arg ( x105_ + 1, ( A ) ) ;\
1378
	x105_->ag_ptr = ( B ) ;\
1379
	( C ) = x105_ ;\
1380
    }
1381
 
1382
#define UN_CONS_arg( A, B, C )\
1383
    {\
1384
	calculus *x106_ = CHECK_NULL ( C ) ;\
1385
	DEREF_arg ( x106_ + 1, ( A ) ) ;\
1386
	( B ) = x106_->ag_ptr ;\
1387
    }
1388
 
1389
#define DESTROY_CONS_arg( D, A, B, C )\
1390
    {\
1391
	calculus *x107_ = CHECK_NULL ( C ) ;\
1392
	DEREF_arg ( x107_ + 1, ( A ) ) ;\
1393
	( B ) = x107_->ag_ptr ;\
1394
	( D ) ( x107_, ( unsigned ) 3 ) ;\
1395
    }
1396
 
1397
#define PUSH_arg( A, B )\
1398
    {\
1399
	calculus **r108_ = &( B ) ;\
1400
	calculus *x108_ = GEN_calculus ( 3, TYPEID_stack ) ;\
1401
	COPY_arg ( x108_ + 1, ( A ) ) ;\
1402
	x108_->ag_ptr = *r108_ ;\
1403
	*r108_ = x108_ ;\
1404
    }
1405
 
1406
#define POP_arg( A, B )\
1407
    {\
1408
	calculus **r109_ = &( B ) ;\
1409
	calculus *x109_ = CHECK_NULL ( *r109_ ) ;\
1410
	DEREF_arg ( x109_ + 1, ( A ) ) ;\
1411
	*r109_ = x109_->ag_ptr ;\
1412
	destroy_calculus ( x109_, ( unsigned ) 3 ) ;\
1413
    }
1414
 
1415
 
1416
/* Definitions for structure MAP */
1417
 
1418
#define map_name( P )			( ( P ) + 0 )
1419
#define map_flag( P )			( ( P ) + 1 )
1420
#define map_ret_type( P )		( ( P ) + 2 )
1421
#define map_args( P )			( ( P ) + 3 )
1422
#define SIZE_map			4
1423
 
1424
#define COPY_map( A, B )\
1425
    {\
1426
	calculus *x110_ = CHECK_NULL ( A ) ;\
1427
	MAP y110_ ;\
1428
	y110_ = ( B ) ;\
1429
	COPY_string ( x110_ + 0, y110_.name ) ;\
1430
	COPY_int ( x110_ + 1, y110_.flag ) ;\
1431
	COPY_ptr ( x110_ + 2, y110_.ret_type ) ;\
1432
	COPY_list ( x110_ + 3, y110_.args ) ;\
1433
    }
1434
 
1435
#define DEREF_map( A, B )\
1436
    {\
1437
	calculus *x111_ = CHECK_NULL ( A ) ;\
1438
	MAP *y111_ = &( B ) ;\
1439
	y111_->name = DEREF_string ( x111_ + 0 ) ;\
1440
	y111_->flag = DEREF_int ( x111_ + 1 ) ;\
1441
	y111_->ret_type = DEREF_ptr ( x111_ + 2 ) ;\
1442
	y111_->args = DEREF_list ( x111_ + 3 ) ;\
1443
    }
1444
 
1445
#define MAKE_map( name_, flag_, ret_type_, args_, map_ )\
1446
    {\
1447
	calculus *x112_ = CHECK_NULL ( map_ ) ;\
1448
	COPY_string ( x112_ + 0, ( name_ ) ) ;\
1449
	COPY_int ( x112_ + 1, ( flag_ ) ) ;\
1450
	COPY_ptr ( x112_ + 2, ( ret_type_ ) ) ;\
1451
	COPY_list ( x112_ + 3, ( args_ ) ) ;\
1452
    }
1453
 
1454
#define CONS_map( A, B, C )\
1455
    {\
1456
	calculus *x113_ = GEN_calculus ( 5, TYPEID_list ) ;\
1457
	COPY_map ( x113_ + 1, ( A ) ) ;\
1458
	x113_->ag_ptr = ( B ) ;\
1459
	( C ) = x113_ ;\
1460
    }
1461
 
1462
#define UN_CONS_map( A, B, C )\
1463
    {\
1464
	calculus *x114_ = CHECK_NULL ( C ) ;\
1465
	DEREF_map ( x114_ + 1, ( A ) ) ;\
1466
	( B ) = x114_->ag_ptr ;\
1467
    }
1468
 
1469
#define DESTROY_CONS_map( D, A, B, C )\
1470
    {\
1471
	calculus *x115_ = CHECK_NULL ( C ) ;\
1472
	DEREF_map ( x115_ + 1, ( A ) ) ;\
1473
	( B ) = x115_->ag_ptr ;\
1474
	( D ) ( x115_, ( unsigned ) 5 ) ;\
1475
    }
1476
 
1477
#define PUSH_map( A, B )\
1478
    {\
1479
	calculus **r116_ = &( B ) ;\
1480
	calculus *x116_ = GEN_calculus ( 5, TYPEID_stack ) ;\
1481
	COPY_map ( x116_ + 1, ( A ) ) ;\
1482
	x116_->ag_ptr = *r116_ ;\
1483
	*r116_ = x116_ ;\
1484
    }
1485
 
1486
#define POP_map( A, B )\
1487
    {\
1488
	calculus **r117_ = &( B ) ;\
1489
	calculus *x117_ = CHECK_NULL ( *r117_ ) ;\
1490
	DEREF_map ( x117_ + 1, ( A ) ) ;\
1491
	*r117_ = x117_->ag_ptr ;\
1492
	destroy_calculus ( x117_, ( unsigned ) 5 ) ;\
1493
    }
1494
 
1495
 
1496
/* Definitions for structure UNION */
1497
 
1498
#define un_id( P )			( ( P ) + 0 )
1499
#define un_base( P )			( ( P ) + 1 )
1500
#define un_s_defn( P )			( ( P ) + 2 )
1501
#define un_u_defn( P )			( ( P ) + 3 )
1502
#define un_map( P )			( ( P ) + 4 )
1503
#define un_no_fields( P )		( ( P ) + 5 )
1504
#define SIZE_un				6
1505
 
1506
#define COPY_un( A, B )\
1507
    {\
1508
	calculus *x118_ = CHECK_NULL ( A ) ;\
1509
	UNION y118_ ;\
1510
	y118_ = ( B ) ;\
1511
	COPY_ptr ( x118_ + 0, y118_.id ) ;\
1512
	COPY_ptr ( x118_ + 1, y118_.base ) ;\
1513
	COPY_list ( x118_ + 2, y118_.s_defn ) ;\
1514
	COPY_list ( x118_ + 3, y118_.u_defn ) ;\
1515
	COPY_list ( x118_ + 4, y118_.map ) ;\
1516
	COPY_int ( x118_ + 5, y118_.no_fields ) ;\
1517
    }
1518
 
1519
#define DEREF_un( A, B )\
1520
    {\
1521
	calculus *x119_ = CHECK_NULL ( A ) ;\
1522
	UNION *y119_ = &( B ) ;\
1523
	y119_->id = DEREF_ptr ( x119_ + 0 ) ;\
1524
	y119_->base = DEREF_ptr ( x119_ + 1 ) ;\
1525
	y119_->s_defn = DEREF_list ( x119_ + 2 ) ;\
1526
	y119_->u_defn = DEREF_list ( x119_ + 3 ) ;\
1527
	y119_->map = DEREF_list ( x119_ + 4 ) ;\
1528
	y119_->no_fields = DEREF_int ( x119_ + 5 ) ;\
1529
    }
1530
 
1531
#define MAKE_un( id_, base_, s_defn_, u_defn_, map_, no_fields_, un_ )\
1532
    {\
1533
	calculus *x120_ = CHECK_NULL ( un_ ) ;\
1534
	COPY_ptr ( x120_ + 0, ( id_ ) ) ;\
1535
	COPY_ptr ( x120_ + 1, ( base_ ) ) ;\
1536
	COPY_list ( x120_ + 2, ( s_defn_ ) ) ;\
1537
	COPY_list ( x120_ + 3, ( u_defn_ ) ) ;\
1538
	COPY_list ( x120_ + 4, ( map_ ) ) ;\
1539
	COPY_int ( x120_ + 5, ( no_fields_ ) ) ;\
1540
    }
1541
 
1542
#define CONS_un( A, B, C )\
1543
    {\
1544
	calculus *x121_ = GEN_calculus ( 7, TYPEID_list ) ;\
1545
	COPY_un ( x121_ + 1, ( A ) ) ;\
1546
	x121_->ag_ptr = ( B ) ;\
1547
	( C ) = x121_ ;\
1548
    }
1549
 
1550
#define UN_CONS_un( A, B, C )\
1551
    {\
1552
	calculus *x122_ = CHECK_NULL ( C ) ;\
1553
	DEREF_un ( x122_ + 1, ( A ) ) ;\
1554
	( B ) = x122_->ag_ptr ;\
1555
    }
1556
 
1557
#define DESTROY_CONS_un( D, A, B, C )\
1558
    {\
1559
	calculus *x123_ = CHECK_NULL ( C ) ;\
1560
	DEREF_un ( x123_ + 1, ( A ) ) ;\
1561
	( B ) = x123_->ag_ptr ;\
1562
	( D ) ( x123_, ( unsigned ) 7 ) ;\
1563
    }
1564
 
1565
#define PUSH_un( A, B )\
1566
    {\
1567
	calculus **r124_ = &( B ) ;\
1568
	calculus *x124_ = GEN_calculus ( 7, TYPEID_stack ) ;\
1569
	COPY_un ( x124_ + 1, ( A ) ) ;\
1570
	x124_->ag_ptr = *r124_ ;\
1571
	*r124_ = x124_ ;\
1572
    }
1573
 
1574
#define POP_un( A, B )\
1575
    {\
1576
	calculus **r125_ = &( B ) ;\
1577
	calculus *x125_ = CHECK_NULL ( *r125_ ) ;\
1578
	DEREF_un ( x125_ + 1, ( A ) ) ;\
1579
	*r125_ = x125_->ag_ptr ;\
1580
	destroy_calculus ( x125_, ( unsigned ) 7 ) ;\
1581
    }
1582
 
1583
 
1584
/* Definitions for union TYPE */
1585
 
1586
#define ORDER_type			( ( unsigned ) 12 )
1587
#define SIZE_type			1
1588
#define NULL_type			( ( TYPE ) 0 )
1589
#define IS_NULL_type( A )		( ( A ) == 0 )
1590
#define EQ_type( A, B )			( ( A ) == ( B ) )
1591
 
1592
#define COPY_type( A, B )		( CHECK_NULL ( A )->ag_ptr = ( B ) )
1593
#define DEREF_type( A )			( CHECK_NULL ( A )->ag_ptr )
1594
 
1595
#define CONS_type( A, B, C )\
1596
    {\
1597
	calculus *x126_ = GEN_calculus ( 2, TYPEID_list ) ;\
1598
	COPY_type ( x126_ + 1, ( A ) ) ;\
1599
	x126_->ag_ptr = ( B ) ;\
1600
	( C ) = x126_ ;\
1601
    }
1602
 
1603
#define UN_CONS_type( A, B, C )\
1604
    {\
1605
	calculus *x127_ = CHECK_NULL ( C ) ;\
1606
	( A ) = DEREF_type ( x127_ + 1 ) ;\
1607
	( B ) = x127_->ag_ptr ;\
1608
    }
1609
 
1610
#define DESTROY_CONS_type( D, A, B, C )\
1611
    {\
1612
	calculus *x128_ = CHECK_NULL ( C ) ;\
1613
	( A ) = DEREF_type ( x128_ + 1 ) ;\
1614
	( B ) = x128_->ag_ptr ;\
1615
	( D ) ( x128_, ( unsigned ) 2 ) ;\
1616
    }
1617
 
1618
#define PUSH_type( A, B )\
1619
    {\
1620
	calculus **r129_ = &( B ) ;\
1621
	calculus *x129_ = GEN_calculus ( 2, TYPEID_stack ) ;\
1622
	COPY_type ( x129_ + 1, ( A ) ) ;\
1623
	x129_->ag_ptr = *r129_ ;\
1624
	*r129_ = x129_ ;\
1625
    }
1626
 
1627
#define POP_type( A, B )\
1628
    {\
1629
	calculus **r130_ = &( B ) ;\
1630
	calculus *x130_ = CHECK_NULL ( *r130_ ) ;\
1631
	( A ) = DEREF_type ( x130_ + 1 ) ;\
1632
	*r130_ = x130_->ag_ptr ;\
1633
	destroy_calculus ( x130_, ( unsigned ) 2 ) ;\
1634
    }
1635
 
1636
 
1637
/* Definitions for union COMMAND */
1638
 
1639
#define ORDER_cmd			( ( unsigned ) 4 )
1640
#define SIZE_cmd			1
1641
#define NULL_cmd			( ( COMMAND ) 0 )
1642
#define IS_NULL_cmd( A )		( ( A ) == 0 )
1643
#define EQ_cmd( A, B )			( ( A ) == ( B ) )
1644
 
1645
#define COPY_cmd( A, B )		( CHECK_NULL ( A )->ag_ptr = ( B ) )
1646
#define DEREF_cmd( A )			( CHECK_NULL ( A )->ag_ptr )
1647
 
1648
#define CONS_cmd( A, B, C )\
1649
    {\
1650
	calculus *x131_ = GEN_calculus ( 2, TYPEID_list ) ;\
1651
	COPY_cmd ( x131_ + 1, ( A ) ) ;\
1652
	x131_->ag_ptr = ( B ) ;\
1653
	( C ) = x131_ ;\
1654
    }
1655
 
1656
#define UN_CONS_cmd( A, B, C )\
1657
    {\
1658
	calculus *x132_ = CHECK_NULL ( C ) ;\
1659
	( A ) = DEREF_cmd ( x132_ + 1 ) ;\
1660
	( B ) = x132_->ag_ptr ;\
1661
    }
1662
 
1663
#define DESTROY_CONS_cmd( D, A, B, C )\
1664
    {\
1665
	calculus *x133_ = CHECK_NULL ( C ) ;\
1666
	( A ) = DEREF_cmd ( x133_ + 1 ) ;\
1667
	( B ) = x133_->ag_ptr ;\
1668
	( D ) ( x133_, ( unsigned ) 2 ) ;\
1669
    }
1670
 
1671
#define PUSH_cmd( A, B )\
1672
    {\
1673
	calculus **r134_ = &( B ) ;\
1674
	calculus *x134_ = GEN_calculus ( 2, TYPEID_stack ) ;\
1675
	COPY_cmd ( x134_ + 1, ( A ) ) ;\
1676
	x134_->ag_ptr = *r134_ ;\
1677
	*r134_ = x134_ ;\
1678
    }
1679
 
1680
#define POP_cmd( A, B )\
1681
    {\
1682
	calculus **r135_ = &( B ) ;\
1683
	calculus *x135_ = CHECK_NULL ( *r135_ ) ;\
1684
	( A ) = DEREF_cmd ( x135_ + 1 ) ;\
1685
	*r135_ = x135_->ag_ptr ;\
1686
	destroy_calculus ( x135_, ( unsigned ) 2 ) ;\
1687
    }
1688
 
1689
 
1690
/* Maximum allocation size */
1691
 
1692
#define calculus_GEN_MAX		11
1693
 
1694
#endif