1.1 --- a/libxml2dom/macrolib/macrolib.py Fri Jun 20 21:41:50 2008 +0200
1.2 +++ b/libxml2dom/macrolib/macrolib.py Fri May 27 20:31:30 2005 +0000
1.3 @@ -310,8 +310,13 @@
1.4 context = libxml2mod.xmlXPathNewContext(Node_ownerDocument(node))
1.5 libxml2mod.xmlXPathSetContextNode(context, node)
1.6 # NOTE: Discover namespaces from the node.
1.7 + # NOTE: Work out how to specify paths without having to use prefixes on
1.8 + # NOTE: names all the time.
1.9 for prefix, ns in (namespaces or {}).items():
1.10 libxml2mod.xmlXPathRegisterNs(context, prefix, ns)
1.11 + # NOTE: No such functions are exposed in current versions of libxml2.
1.12 + #for (prefix, ns), value in (variables or {}).items():
1.13 + # libxml2mod.xmlXPathRegisterVariableNS(context, prefix, ns, value)
1.14 result = libxml2mod.xmlXPathEval(expr, context)
1.15 libxml2mod.xmlXPathFreeContext(context)
1.16 return result