File: dtd.c

package info (click to toggle)
html-xml-utils 6.1-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 1,620 kB
  • sloc: ansic: 10,027; sh: 2,135; lex: 189; yacc: 125; perl: 123; makefile: 122
file content (365 lines) | stat: -rw-r--r-- 25,414 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
/* C code produced by gperf version 3.0.3 */
/* Command-line: gperf -a -c -C -o -t -p -T -k '1,2,$' -N lookup_element dtd.hash  */

#if !((' ' == 32) && ('!' == 33) && ('"' == 34) && ('#' == 35) \
      && ('%' == 37) && ('&' == 38) && ('\'' == 39) && ('(' == 40) \
      && (')' == 41) && ('*' == 42) && ('+' == 43) && (',' == 44) \
      && ('-' == 45) && ('.' == 46) && ('/' == 47) && ('0' == 48) \
      && ('1' == 49) && ('2' == 50) && ('3' == 51) && ('4' == 52) \
      && ('5' == 53) && ('6' == 54) && ('7' == 55) && ('8' == 56) \
      && ('9' == 57) && (':' == 58) && (';' == 59) && ('<' == 60) \
      && ('=' == 61) && ('>' == 62) && ('?' == 63) && ('A' == 65) \
      && ('B' == 66) && ('C' == 67) && ('D' == 68) && ('E' == 69) \
      && ('F' == 70) && ('G' == 71) && ('H' == 72) && ('I' == 73) \
      && ('J' == 74) && ('K' == 75) && ('L' == 76) && ('M' == 77) \
      && ('N' == 78) && ('O' == 79) && ('P' == 80) && ('Q' == 81) \
      && ('R' == 82) && ('S' == 83) && ('T' == 84) && ('U' == 85) \
      && ('V' == 86) && ('W' == 87) && ('X' == 88) && ('Y' == 89) \
      && ('Z' == 90) && ('[' == 91) && ('\\' == 92) && (']' == 93) \
      && ('^' == 94) && ('_' == 95) && ('a' == 97) && ('b' == 98) \
      && ('c' == 99) && ('d' == 100) && ('e' == 101) && ('f' == 102) \
      && ('g' == 103) && ('h' == 104) && ('i' == 105) && ('j' == 106) \
      && ('k' == 107) && ('l' == 108) && ('m' == 109) && ('n' == 110) \
      && ('o' == 111) && ('p' == 112) && ('q' == 113) && ('r' == 114) \
      && ('s' == 115) && ('t' == 116) && ('u' == 117) && ('v' == 118) \
      && ('w' == 119) && ('x' == 120) && ('y' == 121) && ('z' == 122) \
      && ('{' == 123) && ('|' == 124) && ('}' == 125) && ('~' == 126))
/* The character set is not based on ISO-646.  */
error "gperf generated tables don't work with this execution character set. Please report a bug to <bug-gnu-gperf@gnu.org>."
#endif

#line 1 "dtd.hash"
						/* -*-indented-text-*- */

/*
 * Copyright © 1994-2000 World Wide Web Consortium
 * See http://www.w3.org/Consortium/Legal/copyright-software
 *
 * Part of HTML-XML-utils, see:
 * http://www.w3.org/Tools/HTML-XML-utils/
 *
 * Author: Bert Bos <bert@w3.org>
 * Created: 5 Nov 1998
 *
 * Input file for gperf, to generate a perfect hash function
 * for all HTML tags, and to store each element's type.
 *
 * mixed = element accepts text content
 * empty = element is empty
 * stag = start tag is required
 * etag = end tag is required
 * pre = element is preformatted
 * break_before, break_after = pretty-print with a newline before/after the elt
 * parents = array of possible parents, first one is preferred parent
 *
 * The DTD is strict HTML 4.0
 *
 */
#include <config.h>
#include <string.h>
#include <stdlib.h>
#include <assert.h>
#include "export.h"
#include "types.e"

#define MAXNAMELEN 10				/* Max. len. of elt. name */
EXPORTDEF(MAXNAMELEN)

EXPORT typedef struct _ElementType {
  string name;
  Boolean mixed, empty, stag, etag, pre, break_before, break_after;
  string parents[60];
} ElementType;

/* lookup_element -- look up the string in the hash table */
EXPORT const ElementType * lookup_element(register const char *str,
					  register unsigned int len);



#define TOTAL_KEYWORDS 78
#define MIN_WORD_LENGTH 1
#define MAX_WORD_LENGTH 10
#define MIN_HASH_VALUE 1
#define MAX_HASH_VALUE 167
/* maximum key range = 167, duplicates = 0 */

#ifdef __GNUC__
__inline
#else
#ifdef __cplusplus
inline
#endif
#endif
static unsigned int
hash (str, len)
     register const char *str;
     register unsigned int len;
{
  static const unsigned char asso_values[] =
    {
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168,   0, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168,  30,
       25,  20,  15,  10,   5, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168,   0,  60,  20,
        5,   0,  60,  30,  65,  25, 168,  45,  10,  15,
       40,  15,  15,   5,  50,  10,   0,  60,  70, 168,
      168,  20, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
      168, 168, 168, 168, 168, 168
    };
  register int hval = len;

  switch (hval)
    {
      default:
        hval += asso_values[(unsigned char)str[1]];
      /*FALLTHROUGH*/
      case 1:
        hval += asso_values[(unsigned char)str[0]];
        break;
    }
  return hval + asso_values[(unsigned char)str[len - 1]];
}

#ifdef __GNUC__
__inline
#ifdef __GNUC_STDC_INLINE__
__attribute__ ((__gnu_inline__))
#endif
#endif
const ElementType *
lookup_element (str, len)
     register const char *str;
     register unsigned int len;
{
  static const ElementType wordlist[] =
    {
      {""},
#line 55 "dtd.hash"
      {"a",		1, 0, 1, 1, 0, 0, 0, {"p", "abbr", "acronym", "address", "b", "bdo", "big", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 129 "dtd.hash"
      {"tt",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""},
#line 120 "dtd.hash"
      {"table",		0, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""},
#line 78 "dtd.hash"
      {"dt",		1, 0, 1, 0, 0, 1, 1, {"dl", NULL}},
#line 123 "dtd.hash"
      {"textarea",	1, 0, 1, 1, 1, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 54 "dtd.hash"
      {"%data",	1, 0, 1, 0, 0, 0, 0, {"p", NULL}},
#line 110 "dtd.hash"
      {"q",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 122 "dtd.hash"
      {"td",		1, 0, 1, 0, 0, 1, 1, {"tr", NULL}},
      {""}, {""},
#line 117 "dtd.hash"
      {"style",		1, 0, 1, 1, 1, 1, 1, {"head", NULL}},
#line 113 "dtd.hash"
      {"select",		0, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 73 "dtd.hash"
      {"dd",		1, 0, 1, 0, 0, 1, 1, {"dl", NULL}},
#line 74 "dtd.hash"
      {"del",		1, 0, 1, 1, 0, 0, 0, {"p", "body", "a", "abbr", "acronym", "address", "b", "bdo", "big", "blockquote", "button", "caption", "cite", "code", "colgroup", "dd", "dfn", "div", "dl", "dt", "em", "fieldset", "form", "h1", "h2", "h3", "h4", "h5", "h6", "i", "kbd", "label", "legend", "li", "map", "noscript", "object", "ol", "optgroup", "option", "pre", "q", "samp", "select", "small", "span", "strong", "sub", "sup", "table", "tbody", "td", "textarea", "tfoot", "th", "thead", "tt", "ul", "var", NULL}},
#line 101 "dtd.hash"
      {"meta",		0, 1, 1, 0, 0, 0, 1, {"head", NULL}},
      {""},
#line 97 "dtd.hash"
      {"legend",		1, 0, 1, 1, 0, 1, 1, {"fieldset", NULL}},
#line 58 "dtd.hash"
      {"address",	1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""}, {""},
#line 96 "dtd.hash"
      {"label",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 77 "dtd.hash"
      {"dl",		0, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""},
#line 111 "dtd.hash"
      {"samp",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 127 "dtd.hash"
      {"title",		1, 0, 1, 1, 0, 1, 1, {"head", NULL}},
#line 107 "dtd.hash"
      {"p",		1, 0, 1, 0, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 79 "dtd.hash"
      {"em",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 100 "dtd.hash"
      {"map",		0, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 108 "dtd.hash"
      {"param",		0, 1, 1, 0, 0, 1, 1, {"object", NULL}},
#line 112 "dtd.hash"
      {"script",		1, 0, 1, 1, 1, 0, 1, {"p", "body", "a", "abbr", "acronym", "address", "b", "bdo", "big", "blockquote", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 104 "dtd.hash"
      {"ol",		0, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""},
#line 70 "dtd.hash"
      {"code",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 114 "dtd.hash"
      {"small",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 57 "dtd.hash"
      {"acronym",	1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""}, {""},
#line 116 "dtd.hash"
      {"strong",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 71 "dtd.hash"
      {"col",		0, 1, 1, 0, 0, 0, 0, {"colgroup", "table", NULL}},
#line 69 "dtd.hash"
      {"cite",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 91 "dtd.hash"
      {"i",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 105 "dtd.hash"
      {"optgroup",	0, 0, 1, 1, 0, 1, 1, {"select", NULL}},
#line 59 "dtd.hash"
      {"area",		0, 1, 1, 0, 0, 0, 0, {"map", NULL}},
      {""}, {""}, {""},
#line 72 "dtd.hash"
      {"colgroup",	0, 0, 1, 1, 0, 1, 1, {"table", NULL}},
      {""}, {""}, {""},
#line 98 "dtd.hash"
      {"li",		1, 0, 1, 0, 0, 1, 1, {"ul", "ol", NULL}},
#line 102 "dtd.hash"
      {"noscript",	0, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 61 "dtd.hash"
      {"base",		0, 1, 1, 0, 0, 1, 1, {"head", NULL}},
#line 124 "dtd.hash"
      {"tfoot",		0, 0, 1, 0, 0, 1, 1, {"table", NULL}},
      {""},
#line 68 "dtd.hash"
      {"caption",	1, 0, 1, 1, 0, 1, 1, {"table", NULL}},
#line 109 "dtd.hash"
      {"pre",		1, 0, 1, 1, 1, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 115 "dtd.hash"
      {"span",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 93 "dtd.hash"
      {"input",		0, 1, 1, 0, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""},
#line 92 "dtd.hash"
      {"img",		0, 1, 1, 0, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 88 "dtd.hash"
      {"head",		0, 0, 0, 0, 0, 1, 1, {"html", NULL}},
#line 126 "dtd.hash"
      {"thead",		0, 0, 1, 0, 0, 1, 1, {"table", NULL}},
#line 106 "dtd.hash"
      {"option",		1, 0, 1, 0, 0, 1, 1, {"select", "optgroup", NULL}},
#line 87 "dtd.hash"
      {"h6",		1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 94 "dtd.hash"
      {"ins",		1, 0, 1, 1, 0, 0, 0, {"p", "body", "a", "abbr", "acronym", "address", "b", "bdo", "big", "blockquote", "button", "caption", "cite", "code", "colgroup", "dd", "dfn", "div", "dl", "dt", "em", "fieldset", "form", "h1", "h2", "h3", "h4", "h5", "h6", "i", "kbd", "label", "legend", "li", "map", "noscript", "object", "ol", "optgroup", "option", "pre", "q", "samp", "select", "small", "span", "strong", "sub", "sup", "table", "tbody", "td", "textarea", "tfoot", "th", "thead", "tt", "ul", "var", NULL}},
#line 90 "dtd.hash"
      {"html",		0, 0, 0, 0, 0, 1, 1, {NULL, NULL}},
#line 64 "dtd.hash"
      {"blockquote",	0, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 103 "dtd.hash"
      {"object",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "head", "i", "ins", "kbd", "label", "legend", "li", "object", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 130 "dtd.hash"
      {"ul",		0, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 62 "dtd.hash"
      {"bdo",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 99 "dtd.hash"
      {"link",		0, 1, 1, 0, 0, 0, 1, {"head", NULL}},
#line 121 "dtd.hash"
      {"tbody",		0, 0, 0, 0, 0, 1, 1, {"table", NULL}},
      {""},
#line 86 "dtd.hash"
      {"h5",		1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 119 "dtd.hash"
      {"sup",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""}, {""}, {""},
#line 80 "dtd.hash"
      {"fieldset",	1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 81 "dtd.hash"
      {"form",		0, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "dd", "del", "div", "fieldset", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""}, {""},
#line 85 "dtd.hash"
      {"h4",		1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""},
#line 65 "dtd.hash"
      {"body",		0, 0, 0, 0, 0, 1, 1, {"html", NULL}},
      {""}, {""},
#line 128 "dtd.hash"
      {"tr",		0, 0, 1, 0, 0, 1, 1, {"tbody", "tfoot", "thead", NULL}},
#line 76 "dtd.hash"
      {"div",		1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""}, {""}, {""},
#line 84 "dtd.hash"
      {"h3",		1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 75 "dtd.hash"
      {"dfn",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""}, {""}, {""},
#line 95 "dtd.hash"
      {"kbd",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 56 "dtd.hash"
      {"abbr",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""},
#line 83 "dtd.hash"
      {"h2",		1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
#line 63 "dtd.hash"
      {"big",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""},
#line 60 "dtd.hash"
      {"b",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""},
#line 131 "dtd.hash"
      {"var",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""}, {""},
#line 82 "dtd.hash"
      {"h1",		1, 0, 1, 1, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}},
      {""}, {""}, {""}, {""},
#line 125 "dtd.hash"
      {"th",		1, 0, 1, 0, 0, 1, 1, {"tr", NULL}},
#line 118 "dtd.hash"
      {"sub",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""}, {""}, {""}, {""}, {""}, {""}, {""}, {""},
      {""}, {""}, {""}, {""}, {""}, {""}, {""}, {""}, {""},
      {""}, {""}, {""}, {""}, {""}, {""}, {""}, {""}, {""},
      {""},
#line 66 "dtd.hash"
      {"br",		0, 1, 1, 0, 0, 0, 1, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "button", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
      {""}, {""}, {""},
#line 67 "dtd.hash"
      {"button",		1, 0, 1, 1, 0, 0, 0, {"p", "a", "abbr", "acronym", "address", "b", "bdo", "big", "caption", "cite", "code", "dd", "del", "dfn", "div", "dt", "em", "fieldset", "h1", "h2", "h3", "h4", "h5", "h6", "i", "ins", "kbd", "label", "legend", "li", "object", "pre", "q", "samp", "small", "span", "strong", "sub", "sup", "td", "th", "tt", "var", NULL}},
#line 89 "dtd.hash"
      {"hr",		0, 1, 1, 0, 0, 1, 1, {"body", "blockquote", "button", "dd", "del", "div", "fieldset", "form", "ins", "li", "map", "noscript", "object", "td", "th", NULL}}
    };

  if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH)
    {
      register int key = hash (str, len);

      if (key <= MAX_HASH_VALUE && key >= 0)
        {
          register const char *s = wordlist[key].name;

          if (*str == *s && !strncmp (str + 1, s + 1, len - 1) && s[len] == '\0')
            return &wordlist[key];
        }
    }
  return 0;
}
#line 132 "dtd.hash"