5 #if defined(__clang__) || defined(__GNUC__)
6 #pragma GCC diagnostic ignored "-Wunused-parameter"
11 #ifdef COMPILED_FROM_DSP
13 #elif defined(MACOS_CLASSIC)
15 #elif defined(__amigaos__)
17 #elif defined(__WATCOMC__)
18 #include "watcomconfig.h"
20 #ifdef HAVE_EXPAT_CONFIG_H
63 static const char KW_IGNORE[] = {
69 static const char KW_INCLUDE[] = {
92 #ifndef MIN_BYTES_PER_CHAR
93 #define MIN_BYTES_PER_CHAR(enc) ((enc)->minBytesPerChar)
97 #define setTopLevel(state) \
98 ((state)->handler = ((state)->documentEntity \
102 #define setTopLevel(state) ((state)->handler = internalSubset)
123 externalSubset0, externalSubset1,
124 condSect0, condSect1, condSect2,
162 state->handler =
error;
165 return common(state, tok);
193 state->handler =
error;
196 return common(state, tok);
214 state->handler =
error;
217 return common(state, tok);
235 return common(state, tok);
265 return common(state, tok);
282 return common(state, tok);
299 return common(state, tok);
319 return common(state, tok);
336 return common(state, tok);
391 return common(state, tok);
403 state->handler = externalSubset1;
405 return XML_ROLE_TEXT_DECL;
406 return externalSubset1(state, tok, ptr, end, enc);
418 state->handler = condSect0;
421 if (state->includeLevel == 0)
423 state->includeLevel -= 1;
430 if (state->includeLevel)
436 return common(state, tok);
458 return common(state, tok);
475 return common(state, tok);
503 return common(state, tok);
520 return common(state, tok);
537 return common(state, tok);
560 return common(state, tok);
578 return common(state, tok);
606 return common(state, tok);
623 return common(state, tok);
640 return common(state, tok);
657 return common(state, tok);
674 return common(state, tok);
698 return common(state, tok);
715 return common(state, tok);
733 return common(state, tok);
754 return common(state, tok);
772 return common(state, tok);
793 return common(state, tok);
808 static const char *
const types[] = {
819 for (i = 0; i < (
int)(
sizeof(types)/
sizeof(types[0])); i++)
834 return common(state, tok);
853 return common(state, tok);
873 return common(state, tok);
890 return common(state, tok);
907 return common(state, tok);
927 return common(state, tok);
968 return common(state, tok);
985 return common(state, tok);
1003 return common(state, tok);
1033 return common(state, tok);
1073 return common(state, tok);
1098 return common(state, tok);
1116 return common(state, tok);
1137 return common(state, tok);
1167 return common(state, tok);
1182 if (state->
level == 0) {
1189 if (state->
level == 0) {
1196 if (state->
level == 0) {
1203 if (state->
level == 0) {
1215 return common(state, tok);
1232 state->handler = condSect1;
1236 state->handler = condSect2;
1241 return common(state, tok);
1255 state->handler = externalSubset1;
1256 state->includeLevel += 1;
1259 return common(state, tok);
1273 state->handler = externalSubset1;
1274 return XML_ROLE_IGNORE_SECT;
1276 return common(state, tok);
1295 return common(state, tok);
1313 return XML_ROLE_INNER_PARAM_ENTITY_REF;
1315 state->handler =
error;
1324 state->documentEntity = 1;
1325 state->includeLevel = 0;
1326 state->inEntityValue = 0;
1335 state->handler = externalSubset0;
1336 state->documentEntity = 0;
1337 state->includeLevel = 0;