1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-07-28 00:21:53 +03:00

more bug-hunting added --tree to dump the intermediate rng tree patch from

* relaxng.c: more bug-hunting
* testRelax.c include/libxml/relaxng.h: added --tree to dump the
  intermediate rng tree
* python/generator.py: patch from Stephane Bidoul to fix the generator
  on python < 2.2
Daniel
This commit is contained in:
Daniel Veillard
2003-02-16 15:44:18 +00:00
parent d2298791af
commit febcca40d4
5 changed files with 148 additions and 50 deletions

View File

@ -48,6 +48,7 @@
static int debug = 0;
#endif
static int noout = 0;
static int tree = 0;
#ifdef HAVE_SYS_MMAN_H
static int memory = 0;
#endif
@ -71,6 +72,9 @@ int main(int argc, char **argv) {
#endif
if ((!strcmp(argv[i], "-noout")) || (!strcmp(argv[i], "--noout"))) {
noout++;
} else
if ((!strcmp(argv[i], "-tree")) || (!strcmp(argv[i], "--tree"))) {
tree++;
}
}
xmlLineNumbersDefault(1);
@ -123,6 +127,8 @@ int main(int argc, char **argv) {
if (debug)
xmlRelaxNGDump(stdout, schema);
#endif
if (tree)
xmlRelaxNGDumpTree(stdout, schema);
} else {
xmlDocPtr doc;
@ -165,6 +171,7 @@ int main(int argc, char **argv) {
printf("\t--debug : dump a debug tree of the in-memory document\n");
#endif
printf("\t--noout : do not print the result\n");
printf("\t--tree : print the intermediate Relax-NG document tree\n");
#ifdef HAVE_SYS_MMAN_H
printf("\t--memory : test the schemas in memory parsing\n");
#endif