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

- xpath.c include/libxml/xpath.h include/libxml/xpathInternals.h:

lot of optimization work, results in significant improvements
  when handling really complex XPath queries. Add a small optimizer
  for unions, improve [n] and [last()], avoid some costly ops.
Daniel
This commit is contained in:
Daniel Veillard
2001-07-03 10:35:50 +00:00
parent 770447311e
commit f06307e2c1
4 changed files with 1744 additions and 671 deletions

View File

@@ -74,6 +74,17 @@ extern "C" {
if ((ctxt->value == NULL) || (ctxt->value->type != typeval)) \
XP_ERROR(XPATH_INVALID_TYPE)
/**
* CHECK_TYPE0:
* @typeval: the XPath type
*
* Macro to check that the value on top of the XPath stack is of a given
* type. return(0) in case of failure
*/
#define CHECK_TYPE0(typeval) \
if ((ctxt->value == NULL) || (ctxt->value->type != typeval)) \
XP_ERROR0(XPATH_INVALID_TYPE)
/**
* CHECK_ARITY:
* @x: the number of expected args