Further enhancement for XPath streaming, consolidated with schemas usage

* pattern.c, xpath.c, include/libxml/pattern.h: Further
  enhancement for XPath streaming, consolidated with
  schemas usage of pattern.c.  Added a new enum
  xmlPatternFlags.
* doc/*, testapi.c, elfgcchack.h: updated to reflect new
  enum.
* test/XPath/tests/mixedpat, test/XPath/docs/mixed,
  result/XPath/mixedpat: added regression test for problems
  reported in bug306348
diff --git a/xpath.c b/xpath.c
index 8ee0805..6dba293 100644
--- a/xpath.c
+++ b/xpath.c
@@ -11322,7 +11322,8 @@
 	    }
 	}
 
-	stream = xmlPatterncompile(str, dict, 0, &namespaces[0]);
+	stream = xmlPatterncompile(str, dict, XML_PATTERN_XPATH,
+			&namespaces[0]);
 	if ((stream != NULL) && (xmlPatternStreamable(stream) == 1)) {
 	    comp = xmlXPathNewCompExpr();
 	    if (comp == NULL) {