1
0
mirror of https://github.com/GNOME/libxml2.git synced 2025-05-07 20:39:30 +08:00

doc: Fix varargs

This commit is contained in:
Nick Wellnhofer 2025-05-06 18:31:45 +02:00
parent 9bbffec568
commit 38ea8fa9de
9 changed files with 31 additions and 61 deletions

View File

@ -730,20 +730,18 @@ typedef void (*cdataBlockSAXFunc) (
/**
* Display and format a warning messages, callback.
*
* @...: extra parameters for the message display
*
* @param ctx an XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
typedef void (*warningSAXFunc) (void *ctx,
const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
/**
* Display and format an error messages, callback.
*
* @...: extra parameters for the message display
*
* @param ctx an XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
typedef void (*errorSAXFunc) (void *ctx,
const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
@ -752,10 +750,10 @@ typedef void (*errorSAXFunc) (void *ctx,
* Note: so far fatalError() SAX callbacks are not used, error()
* get all the callbacks for errors.
*
* @...: extra parameters for the message display
*
* @param ctx an XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
typedef void (*fatalErrorSAXFunc) (void *ctx,
const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);

View File

@ -32,10 +32,9 @@ typedef xmlRelaxNG *xmlRelaxNGPtr;
/**
* Signature of an error callback from a Relax-NG validation
*
* @...: extra arguments
*
* @param ctx the validation context
* @param msg the message
* @param ... extra arguments
*/
typedef void (*xmlRelaxNGValidityErrorFunc) (void *ctx,
const char *msg,
@ -44,10 +43,9 @@ typedef void (*xmlRelaxNGValidityErrorFunc) (void *ctx,
/**
* Signature of a warning callback from a Relax-NG validation
*
* @...: extra arguments
*
* @param ctx the validation context
* @param msg the message
* @param ... extra arguments
*/
typedef void (*xmlRelaxNGValidityWarningFunc) (void *ctx,
const char *msg,

View File

@ -44,20 +44,18 @@ typedef xmlSchematron *xmlSchematronPtr;
/**
* Signature of an error callback from a Schematron validation
*
* @...: extra arguments
*
* @param ctx the validation context
* @param msg the message
* @param ... extra arguments
*/
typedef void (*xmlSchematronValidityErrorFunc) (void *ctx, const char *msg, ...);
/**
* Signature of a warning callback from a Schematron validation
*
* @...: extra arguments
*
* @param ctx the validation context
* @param msg the message
* @param ... extra arguments
*/
typedef void (*xmlSchematronValidityWarningFunc) (void *ctx, const char *msg, ...);

View File

@ -92,10 +92,9 @@ typedef xmlSchema *xmlSchemaPtr;
/**
* Signature of an error callback from an XSD validation
*
* @...: extra arguments
*
* @param ctx the validation context
* @param msg the message
* @param ... extra arguments
*/
typedef void (*xmlSchemaValidityErrorFunc)
(void *ctx, const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
@ -103,10 +102,9 @@ typedef void (*xmlSchemaValidityErrorFunc)
/**
* Signature of a warning callback from an XSD validation
*
* @...: extra arguments
*
* @param ctx the validation context
* @param msg the message
* @param ... extra arguments
*/
typedef void (*xmlSchemaValidityWarningFunc)
(void *ctx, const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);

View File

@ -395,8 +395,6 @@ xmlCtxtVErr(xmlParserCtxtPtr ctxt, xmlNodePtr node, xmlErrorDomain domain,
/**
* Raise a parser error.
*
* @...: extra parameters for the message display
*
* @param ctxt a parser context
* @param node the current node or NULL
* @param domain the domain for the error
@ -407,6 +405,7 @@ xmlCtxtVErr(xmlParserCtxtPtr ctxt, xmlNodePtr node, xmlErrorDomain domain,
* @param str3 extra string info
* @param int1 extra int info
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
void
xmlCtxtErr(xmlParserCtxtPtr ctxt, xmlNodePtr node, xmlErrorDomain domain,

View File

@ -1121,10 +1121,9 @@ commentDebug(void *ctx ATTRIBUTE_UNUSED, const xmlChar *value)
* Display and format a warning messages, gives file, line, position and
* extra parameters.
*
* @...: extra parameters for the message display
*
* @param ctxt An XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
static void
warningDebug(void *ctx ATTRIBUTE_UNUSED, const char *msg, ...)
@ -1144,10 +1143,9 @@ warningDebug(void *ctx ATTRIBUTE_UNUSED, const char *msg, ...)
* Display and format a error messages, gives file, line, position and
* extra parameters.
*
* @...: extra parameters for the message display
*
* @param ctxt An XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
static void
errorDebug(void *ctx ATTRIBUTE_UNUSED, const char *msg, ...)
@ -1167,10 +1165,9 @@ errorDebug(void *ctx ATTRIBUTE_UNUSED, const char *msg, ...)
* Display and format a fatalError messages, gives file, line, position and
* extra parameters.
*
* @...: extra parameters for the message display
*
* @param ctxt An XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
static void
fatalErrorDebug(void *ctx ATTRIBUTE_UNUSED, const char *msg, ...)

View File

@ -758,10 +758,9 @@ commentCallback(void *ctx ATTRIBUTE_UNUSED,
* Display and format a warning messages, gives file, line, position and
* extra parameters.
*
* @...: extra parameters for the message display
*
* @param ctxt An XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
static void
warningCallback(void *ctx ATTRIBUTE_UNUSED,
@ -774,10 +773,9 @@ warningCallback(void *ctx ATTRIBUTE_UNUSED,
* Display and format a error messages, gives file, line, position and
* extra parameters.
*
* @...: extra parameters for the message display
*
* @param ctxt An XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
static void
errorCallback(void *ctx ATTRIBUTE_UNUSED, const char *msg ATTRIBUTE_UNUSED,
@ -790,10 +788,9 @@ errorCallback(void *ctx ATTRIBUTE_UNUSED, const char *msg ATTRIBUTE_UNUSED,
* Display and format a fatalError messages, gives file, line, position and
* extra parameters.
*
* @...: extra parameters for the message display
*
* @param ctxt An XML parser context
* @param msg the message to display/transmit
* @param ... extra parameters for the message display
*/
static void
fatalErrorCallback(void *ctx ATTRIBUTE_UNUSED,

View File

@ -506,11 +506,10 @@ xmlStrcat(xmlChar *cur, const xmlChar *add) {
/**
* Formats `msg` and places result into `buf`.
*
* @...: extra parameters for the message.
*
* @param buf the result buffer.
* @param len the result buffer length.
* @param msg the message with printf formatting.
* @param ... extra parameters for the message.
* @returns the number of characters written to `buf` or -1 if an error occurs.
*/
int
@ -672,11 +671,10 @@ xmlStrVASPrintf(xmlChar **out, int maxSize, const char *msg, va_list ap) {
/**
* See xmlStrVASPrintf().
*
* @...: arguments for format string
*
* @param out pointer to the resulting string
* @param maxSize maximum size of the output buffer
* @param msg printf format string
* @param ... arguments for format string
* @returns 0 on success, 1 if the result was truncated or on other
* errors, -1 if a memory allocation failed.
*/

View File

@ -822,10 +822,9 @@ xmlTextWriterEndComment(xmlTextWriterPtr writer)
/**
* Write an xml comment.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -1237,10 +1236,9 @@ xmlTextWriterFullEndElement(xmlTextWriterPtr writer)
/**
* Write a formatted raw xml text.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -1356,10 +1354,9 @@ xmlTextWriterWriteRaw(xmlTextWriterPtr writer, const xmlChar * content)
/**
* Write a formatted xml text.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -1880,11 +1877,10 @@ xmlTextWriterEndAttribute(xmlTextWriterPtr writer)
/**
* Write a formatted xml attribute.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param name attribute name
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -1968,13 +1964,12 @@ xmlTextWriterWriteAttribute(xmlTextWriterPtr writer, const xmlChar * name,
/**
* Write a formatted xml attribute.with namespace support
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param prefix namespace prefix
* @param name attribute local name
* @param namespaceURI namespace URI
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -2073,11 +2068,10 @@ xmlTextWriterWriteAttributeNS(xmlTextWriterPtr writer,
/**
* Write a formatted xml element.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param name element name
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -2163,13 +2157,12 @@ xmlTextWriterWriteElement(xmlTextWriterPtr writer, const xmlChar * name,
/**
* Write a formatted xml element with namespace support.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param prefix namespace prefix
* @param name element local name
* @param namespaceURI namespace URI
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -2413,11 +2406,10 @@ xmlTextWriterEndPI(xmlTextWriterPtr writer)
/**
* Write a formatted PI.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param target PI target
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -2620,10 +2612,9 @@ xmlTextWriterEndCDATA(xmlTextWriterPtr writer)
/**
* Write a formatted xml CDATA.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -2917,13 +2908,12 @@ xmlTextWriterEndDTD(xmlTextWriterPtr writer)
/**
* Write a DTD with a formatted markup declarations part.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param name the name of the DTD
* @param pubid the public identifier, which is an alternative to the system identifier
* @param sysid the system identifier, which is the URI of the DTD
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -3154,11 +3144,10 @@ xmlTextWriterEndDTDElement(xmlTextWriterPtr writer)
/**
* Write a formatted DTD element.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param name the name of the DTD element
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -3382,11 +3371,10 @@ xmlTextWriterEndDTDAttlist(xmlTextWriterPtr writer)
/**
* Write a formatted DTD ATTLIST.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param name the name of the DTD ATTLIST
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int
@ -3630,12 +3618,11 @@ xmlTextWriterEndDTDEntity(xmlTextWriterPtr writer)
/**
* Write a formatted DTD internal entity.
*
* @...: extra parameters for the format
*
* @param writer the xmlTextWriterPtr
* @param pe TRUE if this is a parameter entity, FALSE if not
* @param name the name of the DTD entity
* @param format format string (see printf)
* @param ... extra parameters for the format
* @returns the bytes written (may be 0 because of buffering) or -1 in case of error
*/
int