1 /* list_routines.h: Types used in this program.
2 
3 This file is part of Omega,
4 which is based on the web2c distribution of TeX,
5 
6 Copyright (c) 1994--2001 John Plaice and Yannis Haralambous
7 
8 Omega is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version.
12 
13 Omega is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 GNU General Public License for more details.
17 
18 You should have received a copy of the GNU General Public License
19 along with Omega; if not, write to the Free Software Foundation, Inc.,
20 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
21 
22 */
23 
24 typedef int fix;
25 
26 typedef struct cell_struct {
27     struct cell_struct *ptr;
28     void *contents;
29 } cell;
30 typedef cell *list;
31 
32 typedef struct av_cell_struct {
33     struct av_cell_struct *ptr;
34     int attribute;
35     int value;
36 } av_cell;
37 typedef av_cell *av_list;
38 
39 typedef struct in_cell_struct {
40     struct in_cell_struct *ptr;
41     struct in_cell_struct *actual;
42     int value;
43     int index;
44 } in_cell;
45 typedef in_cell *in_list;
46 
47 typedef struct hash_cell_struct {
48     int x;
49     int y;
50     int new_class;
51     int lig_z;
52     struct hash_cell_struct *ptr;
53 } hash_cell;
54 
55 typedef hash_cell *hash_list;
56 
57 typedef struct queue_struct {
58     struct cell_struct *front;
59     struct cell_struct *tail;
60 } queue;
61 
62 extern av_list av_list1(int,int);
63 
64 extern in_list in_list1(int,in_list);
65 
66 extern hash_list hash_list1(int,int,int,int,hash_list);
67 
68 #define lattr(L) (L->attribute)
69 #define lval(L) (L->value)
70 
71 typedef struct four_pieces_struct {
72     unsigned int pieces[4];
73 } four_pieces;
74 
75 typedef struct four_entries_struct {
76     int entries[4];
77 } four_entries;
78 
79 #define lb0(L) (((four_entries *)((L)->contents))->entries[0])
80 #define lb1(L) (((four_entries *)((L)->contents))->entries[1])
81 #define lb2(L) (((four_entries *)((L)->contents))->entries[2])
82 #define lb3(L) (((four_entries *)((L)->contents))->entries[3])
83 
84 
85 extern void append_to_queue(queue *, void *);
86