1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-03-09 04:58:16 +03:00

doc: Update and fix documentation

This commit is contained in:
Nick Wellnhofer 2024-05-20 13:58:22 +02:00
parent 9523438ad4
commit e75e878e02
21 changed files with 239 additions and 34 deletions

View File

@ -6305,9 +6305,12 @@ htmlCtxtUseOptions(htmlParserCtxtPtr ctxt, int options)
/**
* htmlCtxtParseDocument:
* @ctxt: an HTML parser context
* @input: parser input
*
* Parse an HTML document and return the resulting document tree.
*
* Available since 2.13.0.
*
* Returns the resulting document tree or NULL
*/
htmlDocPtr

42
dict.c
View File

@ -510,6 +510,15 @@ xmlDictHashQName(unsigned seed, const xmlChar *prefix, const xmlChar *name,
return(h2 | MAX_HASH_SIZE);
}
/**
* xmlDictComputeHash:
* @dict: dictionary
* @string: C string
*
* Compute the hash value of a C string.
*
* Returns the hash value.
*/
unsigned
xmlDictComputeHash(const xmlDict *dict, const xmlChar *string) {
size_t len;
@ -518,6 +527,15 @@ xmlDictComputeHash(const xmlDict *dict, const xmlChar *string) {
#define HASH_ROL31(x,n) ((x) << (n) | ((x) & 0x7FFFFFFF) >> (31 - (n)))
/**
* xmlDictCombineHash:
* @v1: first hash value
* @v2: second hash value
*
* Combine two hash values.
*
* Returns the combined hash value.
*/
ATTRIBUTE_NO_SANITIZE_INTEGER
unsigned
xmlDictCombineHash(unsigned v1, unsigned v2) {
@ -925,6 +943,11 @@ static xmlMutex xmlRngMutex;
static unsigned globalRngState[2];
/*
* xmlInitRandom:
*
* Initialize the PRNG.
*/
ATTRIBUTE_NO_SANITIZE_INTEGER
void
xmlInitRandom(void) {
@ -966,6 +989,11 @@ xmlInitRandom(void) {
}
}
/*
* xmlCleanupRandom:
*
* Clean up PRNG globals.
*/
void
xmlCleanupRandom(void) {
xmlCleanupMutex(&xmlRngMutex);
@ -985,6 +1013,13 @@ xoroshiro64ss(unsigned *s) {
return(result & 0xFFFFFFFF);
}
/*
* xmlGlobalRandom:
*
* Generate a pseudo-random value using the global PRNG.
*
* Returns a random value.
*/
unsigned
xmlGlobalRandom(void) {
unsigned ret;
@ -996,6 +1031,13 @@ xmlGlobalRandom(void) {
return(ret);
}
/*
* xmlRandom:
*
* Generate a pseudo-random value using the thread-local PRNG.
*
* Returns a random value.
*/
unsigned
xmlRandom(void) {
#ifdef LIBXML_THREAD_ENABLED

View File

@ -70,7 +70,10 @@ static const xmlEntity xmlEntityApos = {
};
/*
* xmlFreeEntity : clean-up an entity record.
* xmlFreeEntity:
* @entity: an entity
*
* Frees the entity.
*/
void
xmlFreeEntity(xmlEntityPtr entity)
@ -174,6 +177,8 @@ error:
*
* Register a new entity for this document.
*
* Available since 2.13.0.
*
* Returns an xmlParserErrors error code.
*/
int

View File

@ -409,6 +409,8 @@ xmlParserPrintFileContext(xmlParserInputPtr input) {
*
* This can result in a verbose multi-line report including additional
* information from the parser context.
*
* Available since 2.13.0.
*/
void
xmlFormatError(const xmlError *err, xmlGenericErrorFunc channel, void *data)
@ -662,7 +664,7 @@ xmlRaiseMemoryError(xmlStructuredErrorFunc schannel, xmlGenericErrorFunc channel
* @channel: the old callback channel
* @data: the callback data
* @ctx: the parser context or NULL
* @ctx: the parser context or NULL
* @node: the current node or NULL
* @domain: the domain for the error
* @code: the code for the error
* @level: the xmlErrorLevel for the error

View File

@ -897,6 +897,11 @@ XML_GLOBALS_TREE
#undef XML_OP
#ifdef LIBXML_THREAD_ENABLED
/**
* xmlGetLocalRngState:
*
* Returns the local RNG state.
*/
unsigned *
xmlGetLocalRngState(void) {
if (IS_MAIN_THREAD)
@ -975,6 +980,8 @@ xmlCheckThreadLocalStorage(void) {
return(0);
}
/** DOC_DISABLE */
/**
* DllMain:
* @hinstDLL: handle to DLL instance
@ -1227,3 +1234,5 @@ xmlThrDefOutputBufferCreateFilenameDefault(xmlOutputBufferCreateFilenameFunc fun
return(old);
}
/** DOC_ENABLE */

12
hash.c
View File

@ -608,6 +608,8 @@ xmlHashDefaultDeallocator(void *entry, const xmlChar *key ATTRIBUTE_UNUSED) {
* can't be distinguished from out-of-memory errors, so this function
* should be used with care.
*
* Available since 2.13.0.
*
* Returns 1 on success, 0 if an entry exists and -1 in case of error.
*/
int
@ -625,6 +627,10 @@ xmlHashAdd(xmlHashTablePtr hash, const xmlChar *key, void *payload) {
* Add a hash table entry with two strings as key.
*
* See xmlHashAdd.
*
* Available since 2.13.0.
*
* Returns 1 on success, 0 if an entry exists and -1 in case of error.
*/
int
xmlHashAdd2(xmlHashTablePtr hash, const xmlChar *key,
@ -643,6 +649,10 @@ xmlHashAdd2(xmlHashTablePtr hash, const xmlChar *key,
* Add a hash table entry with three strings as key.
*
* See xmlHashAdd.
*
* Available since 2.13.0.
*
* Returns 1 on success, 0 if an entry exists and -1 in case of error.
*/
int
xmlHashAdd3(xmlHashTablePtr hash, const xmlChar *key,
@ -1131,6 +1141,8 @@ xmlHashScanFull3(xmlHashTablePtr hash, const xmlChar *key,
*
* Copy the hash table using @copyFunc to copy payloads.
*
* Available since 2.13.0.
*
* Returns the new table or NULL if a memory allocation failed.
*/
xmlHashTablePtr

View File

@ -202,7 +202,9 @@ XMLPUBFUN xmlCharEncoding
xmlDetectCharEncoding (const unsigned char *in,
int len);
/** DOC_DISABLE */
struct _xmlBuffer;
/** DOC_ENABLE */
XMLPUBFUN int
xmlCharEncOutFunc (xmlCharEncodingHandler *handler,
struct _xmlBuffer *out,

View File

@ -927,7 +927,9 @@ XMLPUBFUN void
xmlParserValidityWarning (void *ctx,
const char *msg,
...) LIBXML_ATTR_FORMAT(2,3);
/** DOC_DISABLE */
struct _xmlParserInput;
/** DOC_ENABLE */
XMLPUBFUN void
xmlParserPrintFileInfo (struct _xmlParserInput *input);
XMLPUBFUN void

View File

@ -11671,8 +11671,6 @@ xmlStopParser(xmlParserCtxtPtr ctxt) {
* @ioctx: an I/O handler
* @enc: the charset encoding if known (deprecated)
*
* DEPRECATED: Use xmlNewParserCtxt and xmlCtxtReadIO.
*
* Create a parser context for using the XML parser with an existing
* I/O stream
*
@ -12132,10 +12130,10 @@ error:
/**
* xmlParseCtxtExternalEntity:
* @ctx: the existing parsing context
* @ctxt: the existing parsing context
* @URL: the URL for the entity to load
* @ID: the System ID for the entity to load
* @lst: the return value for the set of parsed nodes
* @listOut: the return value for the set of parsed nodes
*
* Parse an external general entity within an existing parsing context
* An external general parsed entity is well-formed if it matches the
@ -12184,7 +12182,7 @@ xmlParseCtxtExternalEntity(xmlParserCtxtPtr ctxt, const xmlChar *URL,
* @depth: Used for loop detection, use 0
* @URL: the URL for the entity to load
* @ID: the System ID for the entity to load
* @lst: the return value for the set of parsed nodes
* @list: the return value for the set of parsed nodes
*
* DEPRECATED: Use xmlParseCtxtExternalEntity.
*
@ -12461,7 +12459,7 @@ xmlParseInNodeContext(xmlNodePtr node, const char *data, int datalen,
* @user_data: The user data returned on SAX callbacks (possibly NULL)
* @depth: Used for loop detection, use 0
* @string: the input string in UTF8 or ISO-Latin (zero terminated)
* @list: the return value for the set of parsed nodes
* @listOut: the return value for the set of parsed nodes
* @recover: return nodes even if the data is broken (use 0)
*
* Parse a well-balanced chunk of an XML document
@ -13659,6 +13657,8 @@ xmlCtxtSetMaxAmplification(xmlParserCtxtPtr ctxt, unsigned maxAmpl)
* Parse an XML document and return the resulting document tree.
* Takes ownership of the input object.
*
* Available since 2.13.0.
*
* Returns the resulting document tree or NULL
*/
xmlDocPtr

View File

@ -124,9 +124,10 @@ xmlCtxtSetErrorHandler(xmlParserCtxtPtr ctxt, xmlStructuredErrorFunc handler,
/**
* xmlCtxtErrMemory:
* @ctxt: an XML parser context
* @domain: domain
*
* Handle an out-of-memory error
* Handle an out-of-memory error.
*
* Available since 2.13.0.
*/
void
xmlCtxtErrMemory(xmlParserCtxtPtr ctxt)
@ -209,6 +210,22 @@ xmlCtxtErrIO(xmlParserCtxtPtr ctxt, int code, const char *uri)
msg, str1, str2);
}
/**
* xmlCtxtVErr:
* @ctxt: a parser context
* @node: the current node or NULL
* @domain: the domain for the error
* @code: the code for the error
* @level: the xmlErrorLevel for the error
* @str1: extra string info
* @str2: extra string info
* @str3: extra string info
* @int1: extra int info
* @msg: the message to display/transmit
* @ap: extra parameters for the message display
*
* Raise a parser error.
*/
void
xmlCtxtVErr(xmlParserCtxtPtr ctxt, xmlNodePtr node, xmlErrorDomain domain,
xmlParserErrors code, xmlErrorLevel level,
@ -299,6 +316,22 @@ xmlCtxtVErr(xmlParserCtxtPtr ctxt, xmlNodePtr node, xmlErrorDomain domain,
return;
}
/**
* xmlCtxtErr:
* @ctxt: a parser context
* @node: the current node or NULL
* @domain: the domain for the error
* @code: the code for the error
* @level: the xmlErrorLevel for the error
* @str1: extra string info
* @str2: extra string info
* @str3: extra string info
* @int1: extra int info
* @msg: the message to display/transmit
* @...: extra parameters for the message display
*
* Raise a parser error.
*/
void
xmlCtxtErr(xmlParserCtxtPtr ctxt, xmlNodePtr node, xmlErrorDomain domain,
xmlParserErrors code, xmlErrorLevel level,
@ -316,7 +349,7 @@ xmlCtxtErr(xmlParserCtxtPtr ctxt, xmlNodePtr node, xmlErrorDomain domain,
/**
* xmlFatalErr:
* @ctxt: an XML parser context
* @error: the error number
* @code: the error number
* @info: extra information string
*
* Handle a fatal parser error, i.e. violating Well-Formedness constraints
@ -1069,6 +1102,8 @@ xmlSwitchEncoding(xmlParserCtxtPtr ctxt, xmlCharEncoding enc)
* @input: the input strea,
* @encoding: the encoding name
*
* Available since 2.13.0.
*
* Returns 0 in case of success, -1 otherwise
*/
static int
@ -1797,11 +1832,9 @@ xmlNewInputPush(xmlParserCtxtPtr ctxt, const char *url,
/**
* xmlNewIOInputStream:
* @ctxt: an XML parser context
* @input: an I/O Input
* @buf: an input buffer
* @enc: the charset encoding if known
*
* DEPRECATED: Use xmlNewInputURL, xmlNewInputMemory, etc.
*
* Create a new input stream structure encapsulating the @input into
* a stream suitable for the parser.
*
@ -1822,7 +1855,7 @@ xmlNewIOInputStream(xmlParserCtxtPtr ctxt, xmlParserInputBufferPtr buf,
/**
* xmlNewEntityInputStream:
* @ctxt: an XML parser context
* @entity: an Entity pointer
* @ent: an Entity pointer
*
* DEPRECATED: Internal function, do not use.
*
@ -1860,8 +1893,6 @@ xmlNewEntityInputStream(xmlParserCtxtPtr ctxt, xmlEntityPtr ent) {
* @ctxt: an XML parser context
* @buffer: an memory buffer
*
* DEPRECATED: Use xmlNewInputString.
*
* Create a new input stream based on a memory buffer.
*
* Returns the new input stream
@ -2023,8 +2054,6 @@ xmlCheckHTTPInput(xmlParserCtxtPtr ctxt, xmlParserInputPtr ret) {
* @ctxt: an XML parser context
* @filename: the filename to use as entity
*
* DEPRECATED: Use xmlNewInputURL.
*
* Create a new input stream based on a file or an URL.
*
* Returns the new input stream or NULL in case of error
@ -2199,8 +2228,6 @@ xmlGetExternalEntityLoader(void) {
* @ID: the Public ID for the entity to load
* @ctxt: the context in which the entity is called or NULL
*
* DEPRECATED: Use xmlNewInputURL.
*
* Returns the xmlParserInputPtr or NULL
*/
xmlParserInputPtr

View File

@ -2252,7 +2252,7 @@ xmlStreamWantsAnyNode(xmlStreamCtxtPtr streamCtxt)
************************************************************************/
/**
* xmlPatterncompile:
* xmlPatternCompileSafe:
* @pattern: the pattern to compile
* @dict: an optional dictionary for interned strings
* @flags: compilation flags, see xmlPatternFlags
@ -2261,6 +2261,8 @@ xmlStreamWantsAnyNode(xmlStreamCtxtPtr streamCtxt)
*
* Compile a pattern.
*
* Available since 2.13.0.
*
* Returns 0 on success, 1 on error, -1 if a memory allocation failed.
*/
int

42
tree.c
View File

@ -2157,7 +2157,6 @@ xmlNewDocNode(xmlDocPtr doc, xmlNsPtr ns,
/**
* xmlNewDocNodeEatName:
* xmlNewDocNode:
* @doc: the target document
* @ns: namespace (optional)
* @name: the node name
@ -4156,6 +4155,17 @@ xmlCopyPropList(xmlNodePtr target, xmlAttrPtr cur) {
* namespace info, but don't recurse on children.
*/
/**
* xmlStaticCopyNode:
* @node: source node
* @doc: target document
* @parent: target parent
* @extended: flags
*
* Copy a node.
*
* Returns the copy or NULL if a memory allocation failed.
*/
xmlNodePtr
xmlStaticCopyNode(xmlNodePtr node, xmlDocPtr doc, xmlNodePtr parent,
int extended) {
@ -5327,7 +5337,7 @@ xmlNodeSetBase(xmlNodePtr cur, const xmlChar* uri) {
#endif /* LIBXML_TREE_ENABLED */
/**
* xmlNodeGetBase:
* xmlNodeGetBaseSafe:
* @doc: the document the node pertains to
* @cur: the node being checked
* @baseOut: pointer to base
@ -5341,6 +5351,8 @@ xmlNodeSetBase(xmlNodePtr cur, const xmlChar* uri) {
* However it does not return the document base (5.1.3), use
* doc->URL in this case
*
* Available since 2.13.0.
*
* Return 0 in case of success, 1 if a URI or argument is invalid, -1 if a
* memory allocation failed.
*/
@ -5866,6 +5878,8 @@ xmlTextMerge(xmlNodePtr first, xmlNodePtr second) {
* terminated array of namespace pointers that must be freed by
* the caller.
*
* Available since 2.13.0.
*
* Returns 0 on success, 1 if no namespaces were found, -1 if a
* memory allocation failed.
*/
@ -5991,6 +6005,17 @@ xmlTreeEnsureXMLDecl(xmlDocPtr doc)
return(ns);
}
/**
* xmlSearchNsSafe:
* @node: a node
* @prefix: a namespace prefix
* @out: pointer to resulting namespace
*
* Search a namespace with @prefix in scope of @node.
*
* Returns 0 on success, -1 if a memory allocation failed, 1 on
* other errors.
*/
int
xmlSearchNsSafe(xmlNodePtr node, const xmlChar *prefix,
xmlNsPtr *out) {
@ -6132,6 +6157,17 @@ xmlNsInScope(xmlDocPtr doc ATTRIBUTE_UNUSED, xmlNodePtr node,
return (1);
}
/**
* xmlSearchNsByHrefSafe:
* @node: a node
* @href: a namespace URI
* @out: pointer to resulting namespace
*
* Search a namespace matching @URI in scope of @node.
*
* Returns 0 on success, -1 if a memory allocation failed, 1 on
* other errors.
*/
int
xmlSearchNsByHrefSafe(xmlNodePtr node, const xmlChar *href,
xmlNsPtr *out) {
@ -6693,6 +6729,8 @@ xmlHasNsProp(const xmlNode *node, const xmlChar *name, const xmlChar *nameSpace)
* This does the entity substitution. The returned value must be
* freed by the caller.
*
* Available since 2.13.0.
*
* Returns 0 on success, 1 if no attribute was found, -1 if a
* memory allocation failed.
*/

10
uri.c
View File

@ -970,6 +970,8 @@ xmlParse3986URIReference(xmlURIPtr uri, const char *str) {
*
* URI-reference = [ absoluteURI | relativeURI ] [ "#" fragment ]
*
* Available since 2.13.0.
*
* Returns 0 on success, an error code (typically 1) if the URI is invalid
* or -1 if a memory allocation failed.
*/
@ -1989,7 +1991,7 @@ err_memory:
}
/**
* xmlBulidURISafe:
* xmlBuildURISafe:
* @URI: the URI instance found in the document
* @base: the base value
* @valPtr: pointer to result URI
@ -2001,6 +2003,8 @@ err_memory:
*
* 5.2. Resolving Relative References to Absolute Form
*
* Available since 2.13.0.
*
* Returns 0 on success, -1 if a memory allocation failed or an error
* code if URI or base are invalid.
*/
@ -2378,6 +2382,8 @@ xmlBuildURI(const xmlChar *URI, const xmlChar *base) {
* since this routine (for reasonable efficiency) assumes URI has
* already been through some validation.
*
* Available since 2.13.0.
*
* Returns 0 on success, -1 if a memory allocation failed or an error
* code if URI or base are invalid.
*/
@ -2650,6 +2656,8 @@ xmlBuildRelativeURI(const xmlChar * URI, const xmlChar * base)
* The caller is responsible for freeing the memory occupied
* by the returned string. If there is insufficient memory available, or the
* argument is NULL, the function returns NULL.
*
* Returns the escaped path.
*/
xmlChar *
xmlCanonicPath(const xmlChar *path)

View File

@ -2394,6 +2394,8 @@ done:
*
* Register a new id declaration
*
* Available since 2.13.0.
*
* Returns 1 on success, 0 if the ID already exists, -1 if a memory
* allocation fails.
*/

View File

@ -2207,6 +2207,8 @@ xmlXIncludeDoProcessRoot(xmlXIncludeCtxtPtr ctxt, xmlNodePtr tree) {
* xmlXIncludeGetLastError:
* @ctxt: an XInclude processing context
*
* Available since 2.13.0.
*
* Returns the last error code.
*/
int

24
xmlIO.c
View File

@ -1651,6 +1651,8 @@ xmlParserInputBufferCreateFilename(const char *URI, xmlCharEncoding enc) {
* @enc: encoding enum (deprecated)
* @out: pointer to resulting input buffer
*
* Create an input buffer for a filename or URI.
*
* Returns an xmlParserErrors code.
*/
int
@ -1937,6 +1939,17 @@ xmlMemClose(void *vctxt) {
return(0);
}
/**
* xmlNewInputBufferMemory:
* @mem: memory buffer
* @size: size of buffer
* @flags: flags
* @enc: the charset encoding if known (deprecated)
*
* Create an input buffer for memory.
*
* Returns the new input buffer or NULL.
*/
xmlParserInputBufferPtr
xmlNewInputBufferMemory(const void *mem, size_t size, int flags,
xmlCharEncoding enc) {
@ -2059,6 +2072,15 @@ xmlStringClose(void *vctxt) {
return(0);
}
/**
* xmlNewInputBufferString:
* @str: C string
* @flags: flags
*
* Create an input buffer for a null-teriminated C string.
*
* Returns the new input buffer or NULL.
*/
xmlParserInputBufferPtr
xmlNewInputBufferString(const char *str, int flags) {
xmlParserInputBufferPtr ret;
@ -2894,6 +2916,8 @@ xmlParserGetDirectory(const char *filename) {
* DEPRECATED: Internal function, don't use.
*
* Like xmlCheckFilename but handles file URIs.
*
* Returns 0, 1, or 2.
*/
int
xmlNoNetExists(const char *filename) {

View File

@ -395,6 +395,8 @@ xmlMemoryDump(void)
* xmlInitMemory:
*
* DEPRECATED: Alias for xmlInitParser.
*
* Returns 0.
*/
int
xmlInitMemory(void) {
@ -406,8 +408,6 @@ xmlInitMemory(void) {
* xmlInitMemoryInternal:
*
* Initialize the memory layer.
*
* Returns 0 on success
*/
void
xmlInitMemoryInternal(void) {

View File

@ -5042,6 +5042,14 @@ xmlTextReaderSetMaxAmplification(xmlTextReaderPtr reader, unsigned maxAmpl)
xmlCtxtSetMaxAmplification(reader->ctxt, maxAmpl);
}
/**
* xmlTextReaderGetLastError:
* @reader: an XML reader
*
* Available since 2.13.0.
*
* Returns the last error.
*/
const xmlError *
xmlTextReaderGetLastError(xmlTextReaderPtr reader)
{

View File

@ -2164,6 +2164,15 @@ xmlSaveTree(xmlSaveCtxtPtr ctxt, xmlNodePtr cur)
return(ret);
}
/**
* xmlSaveNotationDecl:
* @ctxt: save context
* @cur: notation
*
* Serialize a notation declaration.
*
* Return 0 on succes, -1 on error.
*/
int
xmlSaveNotationDecl(xmlSaveCtxtPtr ctxt, xmlNotationPtr cur) {
if (ctxt == NULL)
@ -2172,6 +2181,15 @@ xmlSaveNotationDecl(xmlSaveCtxtPtr ctxt, xmlNotationPtr cur) {
return(0);
}
/**
* xmlSaveNotationTable:
* @ctxt: save context
* @cur: notation table
*
* Serialize notation declarations of a document.
*
* Return 0 on succes, -1 on error.
*/
int
xmlSaveNotationTable(xmlSaveCtxtPtr ctxt, xmlNotationTablePtr cur) {
if (ctxt == NULL)
@ -2224,6 +2242,8 @@ xmlSaveClose(xmlSaveCtxtPtr ctxt)
* Close a document saving context, i.e. make sure that all bytes have
* been output and free the associated data.
*
* Available since 2.13.0.
*
* Returns an xmlParserErrors code.
*/
int
@ -2283,7 +2303,6 @@ xmlSaveSetAttrEscape(xmlSaveCtxtPtr ctxt, xmlCharEncodingOutputFunc escape)
* xmlBufAttrSerializeTxtContent:
* @buf: output buffer
* @doc: the document
* @attr: the attribute node
* @string: the text content
*
* Serialize text attribute values to an xmlBufPtr

View File

@ -597,7 +597,7 @@ xmlStrVPrintf(xmlChar *buf, int len, const char *msg, va_list ap) {
* xmlStrVASPrintf:
* @out: pointer to the resulting string
* @maxSize: maximum size of the output buffer
* @fmt: printf format string
* @msg: printf format string
* @ap: arguments for format string
*
* Creates a newly allocated string according to format.
@ -715,8 +715,8 @@ xmlStrVASPrintf(xmlChar **out, int maxSize, const char *msg, va_list ap) {
* xmlStrASPrintf:
* @out: pointer to the resulting string
* @maxSize: maximum size of the output buffer
* @fmt: printf format string
* @ap: arguments for format string
* @msg: printf format string
* @...: arguments for format string
*
* See xmlStrVASPrintf.
*

View File

@ -624,7 +624,6 @@ static const char* const xmlXPathErrorMessages[] = {
/**
* xmlXPathErrMemory:
* @ctxt: an XPath context
* @extra: extra information
*
* Handle a memory allocation failure.
*/
@ -640,7 +639,6 @@ xmlXPathErrMemory(xmlXPathContextPtr ctxt)
/**
* xmlXPathPErrMemory:
* @ctxt: an XPath parser context
* @extra: extra information
*
* Handle a memory allocation failure.
*/
@ -656,7 +654,7 @@ xmlXPathPErrMemory(xmlXPathParserContextPtr ctxt)
/**
* xmlXPathErr:
* @ctxt: a XPath parser context
* @error: the error code
* @code: the error code
*
* Handle an XPath error
*/