1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-07-29 11:41:22 +03:00

when creating a DOCTYPE use "html" lowercase by default instead of "HTML"

* HTMLparser.c: when creating a DOCTYPE use "html" lowercase
  by default instead of "HTML"
* parser.c xmlreader.c: optimization, gain a few % parsing speed by
  avoiding calls to "areBlanks" when not needed.
* include/libxml/parser.h include/libxml/tree.h: some structure
  extensions for future work on using per-document dictionaries.
Daniel
This commit is contained in:
Daniel Veillard
2003-09-03 13:28:32 +00:00
parent 4b1577f14a
commit 40412cda44
6 changed files with 30 additions and 13 deletions

View File

@ -1125,6 +1125,7 @@ xmlNewTextReader(xmlParserInputBufferPtr input, const char *URI) {
ret->sax->endElement = xmlTextReaderEndElement;
ret->characters = ret->sax->characters;
ret->sax->characters = xmlTextReaderCharacters;
ret->sax->ignorableWhitespace = xmlTextReaderCharacters;
ret->cdataBlock = ret->sax->cdataBlock;
ret->sax->cdataBlock = xmlTextReaderCDataBlock;
@ -1152,6 +1153,10 @@ xmlNewTextReader(xmlParserInputBufferPtr input, const char *URI) {
ret->ctxt->_private = ret;
ret->ctxt->linenumbers = 1;
ret->allocs = XML_TEXTREADER_CTXT;
/*
* use the parser dictionnary to allocate all elements and attributes names
*/
ret->ctxt->docdict = 1;
return(ret);
}