From: Peter Johnson Date: Mon, 16 Jul 2007 04:42:02 +0000 (-0000) Subject: Doxygen documentation fixes. X-Git-Tag: v0.6.2~8^2~15 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a310410911641fd846d668e91aa14abc0f00e404;p=yasm Doxygen documentation fixes. svn path=/trunk/yasm/; revision=1897 --- diff --git a/libyasm/bytecode.h b/libyasm/bytecode.h index 0cf1888a..afe8b147 100644 --- a/libyasm/bytecode.h +++ b/libyasm/bytecode.h @@ -36,9 +36,10 @@ /** A data value (opaque type). */ typedef struct yasm_dataval yasm_dataval; -/** A list of data values (opaque type). */ +/** A list of data values. */ typedef struct yasm_datavalhead yasm_datavalhead; +/** Linked list of data values. */ /*@reldef@*/ STAILQ_HEAD(yasm_datavalhead, yasm_dataval); /** Add a dependent span for a bytecode. @@ -128,21 +129,19 @@ typedef struct yasm_bytecode_callback { * A generic fill-in for this is yasm_bc_tobytes_common(), but as this * function internal errors when called, be very careful when using it! * \param bc bytecode - * \param buf byte representation destination buffer - * \param bufsize size of buf (in bytes) prior to call; size of the - * generated data after call - * \param gap if nonzero, indicates the data does not really - * need to exist in the object file; if nonzero, - * contents of buf are undefined [output] + * \param bufp byte representation destination buffer; + * should be incremented as it's written to, + * so that on return its delta from the + * passed-in buf matches the bytecode length + * (it's okay not to do this if an error + * indication is returned) * \param d data to pass to each call to * output_value/output_reloc * \param output_value function to call to convert values into their byte * representation * \param output_reloc function to call to output relocation entries * for a single sym - * \return Newly allocated buffer that should be used instead of buf for - * reading the byte representation, or NULL if buf was big enough - * to hold the entire byte representation. + * \return Nonzero on error, 0 on success. * \note May result in non-reversible changes to the bytecode, but it's * preferable if calling this function twice would result in the * same output. @@ -520,7 +519,9 @@ yasm_dataval *yasm_dv_create_raw(/*@keep@*/ unsigned char *contents, * \param headp list of data values */ void yasm_dvs_initialize(yasm_datavalhead *headp); +#ifndef YASM_DOXYGEN #define yasm_dvs_initialize(headp) STAILQ_INIT(headp) +#endif /** Delete (free allocated memory for) a list of data values. * \param headp list of data values diff --git a/libyasm/expr.h b/libyasm/expr.h index 694ba72e..61975674 100644 --- a/libyasm/expr.h +++ b/libyasm/expr.h @@ -158,7 +158,9 @@ struct yasm_expr { * \return Newly allocated expression identical to e. */ yasm_expr *yasm_expr_copy(const yasm_expr *e); +#ifndef YASM_DOXYGEN #define yasm_expr_copy(e) yasm_expr__copy_except(e, -1) +#endif /** Destroy (free allocated memory for) an expression. * \param e expression diff --git a/libyasm/section.h b/libyasm/section.h index ff18e331..bb7d3c13 100644 --- a/libyasm/section.h +++ b/libyasm/section.h @@ -40,7 +40,7 @@ typedef struct yasm_reloc yasm_reloc; struct yasm_reloc { - /*@reldef@*/ STAILQ_ENTRY(yasm_reloc) link; + /*@reldef@*/ STAILQ_ENTRY(yasm_reloc) link; /**< Link to next reloc */ yasm_intnum *addr; /**< Offset (address) within section */ /*@dependent@*/ yasm_symrec *sym; /**< Relocated symbol */ }; @@ -252,7 +252,9 @@ void yasm_section_add_reloc(yasm_section *sect, yasm_reloc *reloc, * \return Next relocation for section. NULL if no more relocations. */ /*@null@*/ yasm_reloc *yasm_section_reloc_next(yasm_reloc *reloc); +#ifndef YASM_DOXYGEN #define yasm_section_reloc_next(x) STAILQ_NEXT((x), link) +#endif /** Get the basic relocation information for a relocation. * \param reloc relocation diff --git a/libyasm/valparam.h b/libyasm/valparam.h index d33a3cf6..9646718a 100644 --- a/libyasm/valparam.h +++ b/libyasm/valparam.h @@ -39,23 +39,25 @@ struct yasm_valparam { /*@reldef@*/ STAILQ_ENTRY(yasm_valparam) link; /**< Next pair in list */ /*@owned@*/ /*@null@*/ char *val; /**< Value */ + /** Parameter type. */ enum yasm_param_type { YASM_PARAM_ID, /**< Identifier */ YASM_PARAM_STRING, /**< String */ YASM_PARAM_EXPR /**< Expression */ } type; /**< Parameter type */ + /** Parameter value. */ union yasm_param { /*@owned@*/ char *id; /**< Identifier */ /*@owned@*/ char *str; /**< String */ /*@owned@*/ yasm_expr *e; /**< Expression */ } param; /**< Parameter */ - /* Prefix character that indicates a raw identifier. When yasm_vp_string() - * is called on a #YASM_PARAM_ID, all characters are returned. When - * yasm_vp_id() is called on a #YASM_PARAM_ID, if the identifier begins - * with this character, this character is stripped from the returned - * value. + /** Prefix character that indicates a raw identifier. When + * yasm_vp_string() is called on a #YASM_PARAM_ID, all characters are + * returned. When yasm_vp_id() is called on a #YASM_PARAM_ID, if the + * identifier begins with this character, this character is stripped + * from the returned value. */ char id_prefix; }; @@ -168,7 +170,9 @@ void yasm_vps_destroy(yasm_valparamhead *headp); * \param headp linked list */ void yasm_vps_initialize(/*@out@*/ yasm_valparamhead *headp); +#ifndef YASM_DOXYGEN #define yasm_vps_initialize(headp) STAILQ_INIT(headp) +#endif /** Destroy (free allocated memory for) linked list of valparams (created with * yasm_vps_initialize). @@ -182,10 +186,12 @@ void yasm_vps_delete(yasm_valparamhead *headp); * \param vp valparam */ void yasm_vps_append(yasm_valparamhead *headp, /*@keep@*/ yasm_valparam *vp); +#ifndef YASM_DOXYGEN #define yasm_vps_append(headp, vp) do { \ if (vp) \ STAILQ_INSERT_TAIL(headp, vp, link); \ } while(0) +#endif /** Get first valparam in linked list. * \param headp linked list @@ -193,21 +199,27 @@ void yasm_vps_append(yasm_valparamhead *headp, /*@keep@*/ yasm_valparam *vp); */ /*@null@*/ /*@dependent@*/ yasm_valparam *yasm_vps_first (yasm_valparamhead *headp); +#ifndef YASM_DOXYGEN #define yasm_vps_first(headp) STAILQ_FIRST(headp) +#endif /** Get next valparam in linked list. * \param cur previous valparam in linked list * \return Next valparam in linked list. */ /*@null@*/ /*@dependent@*/ yasm_valparam *yasm_vps_next(yasm_valparam *cur); +#ifndef YASM_DOXYGEN #define yasm_vps_next(cur) STAILQ_NEXT(cur, link) +#endif /** Iterate through linked list of valparams. * \internal * \param iter iterator variable * \param headp linked list */ +#ifndef YASM_DOXYGEN #define yasm_vps_foreach(iter, headp) STAILQ_FOREACH(iter, headp, link) +#endif /** Print linked list of valparams. For debugging purposes. * \param f file