1 /* BEGIN INCLUDE FILE ... pl1_macro_dtype_procs.incl.pl1 */
 2 both_arithmetic:
 3      procedure (opr1, opr2) returns (bit (1));
 4           declare (opr1, opr2)           fixed binary;      /* INPUT - indixes of tokens */
 5 
 6           if token (opr1).type = dec_integer & token (opr2).type = dec_integer
 7           then return ("1"b);
 8           else return ("0"b);
 9      end both_arithmetic;
10 
11 both_bit_string:
12      procedure (oprx1, oprx2) returns (bit (1));
13           declare (oprx1, oprx2)         fixed binary;
14 
15           if token (oprx1).type = bit_string & token (oprx2).type = bit_string
16           then return ("1"b);
17           else return ("0"b);
18 
19      end both_bit_string;
20 
21 
22 both_char_string:
23      procedure (z1, z2) returns (bit (1));
24           declare (z1, z2)               fixed binary;
25 
26           if token (z1).type = char_string & token (z2).type = char_string
27           then return ("1"b);
28           else return ("0"b);
29      end both_char_string;
30 
31 both_identifier:
32      procedure (z1, z2) returns (bit (1));
33           declare (z1, z2)              fixed binary;
34 
35           if token (z1).type = identifier & token (z2).type = identifier
36           then return ("1"b);
37           else return ("0"b);
38      end both_identifier;
39 
40 op_mix:
41      procedure (x1, x2) returns (fixed binary);
42           declare (x1, x2)               fixed binary;
43 
44           if both_arithmetic (x1, x2)
45           then return (1);
46           else if both_bit_string (x1, x2)
47           then return (2);
48           else if both_char_string (x1, x2)
49           then return (3);
50           else if both_identifier (x1,x2)
51           then return (4);
52           else return (none);
53      end op_mix;
54 /* END INCLUDE FILE ... pl1_macro_dtype_procs.incl.pl1 */