From ab13bd719e5dc229fc37ded795d4a8e4fb8a9a54 Mon Sep 17 00:00:00 2001 From: Peter Johnson Date: Sat, 14 Jul 2007 03:11:32 +0000 Subject: [PATCH] Remove YASM_LIB_INTERNAL. It never really gained us that much in terms of visibility savings, as basically everything defined it. svn path=/trunk/yasm/; revision=1893 --- libyasm.h | 11 +---------- libyasm/assocdat.c | 1 - libyasm/bc-align.c | 1 - libyasm/bc-data.c | 9 --------- libyasm/bc-incbin.c | 1 - libyasm/bc-org.c | 1 - libyasm/bc-reserve.c | 1 - libyasm/bitvect.c | 1 - libyasm/bytecode.c | 1 - libyasm/bytecode.h | 8 +------- libyasm/errwarn.c | 1 - libyasm/expr.c | 1 - libyasm/floatnum.c | 1 - libyasm/hamt.c | 1 - libyasm/insn.c | 17 ---------------- libyasm/insn.h | 7 +------ libyasm/intnum.c | 1 - libyasm/inttree.c | 1 - libyasm/linemap.c | 1 - libyasm/mergesort.c | 1 - libyasm/phash.c | 1 - libyasm/section.c | 1 - libyasm/section.h | 7 ------- libyasm/strcasecmp.c | 1 - libyasm/strsep.c | 1 - libyasm/symrec.c | 1 - libyasm/valparam.c | 26 ------------------------- libyasm/valparam.h | 11 +---------- libyasm/value.c | 1 - libyasm/xmalloc.c | 1 - libyasm/xstrdup.c | 1 - modules/arch/lc3b/lc3barch.c | 1 - modules/arch/lc3b/lc3bbc.c | 1 - modules/arch/lc3b/lc3bid.re | 1 - modules/arch/x86/x86arch.c | 1 - modules/arch/x86/x86bc.c | 1 - modules/arch/x86/x86expr.c | 1 - modules/arch/x86/x86id.c | 1 - modules/dbgfmts/codeview/cv-dbgfmt.c | 1 - modules/dbgfmts/codeview/cv-symline.c | 1 - modules/dbgfmts/codeview/cv-type.c | 1 - modules/dbgfmts/dwarf2/dwarf2-aranges.c | 1 - modules/dbgfmts/dwarf2/dwarf2-dbgfmt.c | 1 - modules/dbgfmts/dwarf2/dwarf2-info.c | 1 - modules/dbgfmts/dwarf2/dwarf2-line.c | 1 - modules/dbgfmts/null/null-dbgfmt.c | 1 - modules/dbgfmts/stabs/stabs-dbgfmt.c | 1 - modules/listfmts/nasm/nasm-listfmt.c | 1 - modules/objfmts/bin/bin-objfmt.c | 1 - modules/objfmts/coff/coff-objfmt.c | 1 - modules/objfmts/coff/win64-except.c | 1 - modules/objfmts/dbg/dbg-objfmt.c | 1 - modules/objfmts/elf/elf-objfmt.c | 1 - modules/objfmts/elf/elf-x86-amd64.c | 1 - modules/objfmts/elf/elf-x86-x86.c | 1 - modules/objfmts/elf/elf.c | 1 - modules/objfmts/macho/macho-objfmt.c | 1 - modules/objfmts/rdf/rdf-objfmt.c | 1 - modules/objfmts/xdf/xdf-objfmt.c | 1 - modules/parsers/gas/gas-parse.c | 1 - modules/parsers/gas/gas-parser.c | 1 - modules/parsers/gas/gas-token.re | 1 - modules/parsers/nasm/nasm-parse.c | 1 - modules/parsers/nasm/nasm-parser.c | 1 - modules/parsers/nasm/nasm-token.re | 1 - modules/preprocs/nasm/nasm-preproc.c | 1 - modules/preprocs/raw/raw-preproc.c | 1 - modules/preprocs/yapp/yapp-preproc.c | 1 - 68 files changed, 4 insertions(+), 152 deletions(-) diff --git a/libyasm.h b/libyasm.h index 8fb7aca7..91596b7f 100644 --- a/libyasm.h +++ b/libyasm.h @@ -31,10 +31,6 @@ * POSSIBILITY OF SUCH DAMAGE. * \endlicense * - * Define YASM_LIB_INTERNAL to include many internal function and variable - * definitions that violate the yasm_* namespace. This includes - * compat-queue.h, bitvect.h, and hamt.h. - * * Additional parts may be included via: * - YASM_BC_INTERNAL: reveal bytecode internal structures via bc-int.h * inclusion @@ -55,9 +51,7 @@ typedef unsigned long uintptr_t; #include #endif -#ifdef YASM_LIB_INTERNAL -# include -#endif +#include #include #include @@ -85,7 +79,6 @@ typedef unsigned long uintptr_t; #include #include -#ifdef YASM_LIB_INTERNAL #ifdef YASM_BC_INTERNAL #include #endif @@ -93,8 +86,6 @@ typedef unsigned long uintptr_t; #include #endif #include -#include #include -#endif #endif diff --git a/libyasm/assocdat.c b/libyasm/assocdat.c index f27b2b41..8364d6c3 100644 --- a/libyasm/assocdat.c +++ b/libyasm/assocdat.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/bc-align.c b/libyasm/bc-align.c index dec63a2b..52474e71 100644 --- a/libyasm/bc-align.c +++ b/libyasm/bc-align.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/bc-data.c b/libyasm/bc-data.c index 50851eb1..cb7dc310 100644 --- a/libyasm/bc-data.c +++ b/libyasm/bc-data.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); @@ -451,11 +450,3 @@ yasm_dvs_print(const yasm_datavalhead *head, FILE *f, int indent_level) } } } - -/* Non-macro yasm_dvs_initialize() for non-YASM_LIB_INTERNAL users. */ -#undef yasm_dvs_initialize -void -yasm_dvs_initialize(yasm_datavalhead *headp) -{ - STAILQ_INIT(headp); -} diff --git a/libyasm/bc-incbin.c b/libyasm/bc-incbin.c index f97f6901..13703105 100644 --- a/libyasm/bc-incbin.c +++ b/libyasm/bc-incbin.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/bc-org.c b/libyasm/bc-org.c index 0b73c79f..da1f743d 100644 --- a/libyasm/bc-org.c +++ b/libyasm/bc-org.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/bc-reserve.c b/libyasm/bc-reserve.c index 9acde378..66224dcf 100644 --- a/libyasm/bc-reserve.c +++ b/libyasm/bc-reserve.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/bitvect.c b/libyasm/bitvect.c index 3fbe0b95..49f19b26 100644 --- a/libyasm/bitvect.c +++ b/libyasm/bitvect.c @@ -1,4 +1,3 @@ -#define YASM_LIB_INTERNAL #include "util.h" RCSID("$Id$"); diff --git a/libyasm/bytecode.c b/libyasm/bytecode.c index d9c89282..e8ea9872 100644 --- a/libyasm/bytecode.c +++ b/libyasm/bytecode.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/bytecode.h b/libyasm/bytecode.h index ef693ed3..8fa273bd 100644 --- a/libyasm/bytecode.h +++ b/libyasm/bytecode.h @@ -39,9 +39,7 @@ typedef struct yasm_dataval yasm_dataval; /** A list of data values (opaque type). */ typedef struct yasm_datavalhead yasm_datavalhead; -#ifdef YASM_LIB_INTERNAL /*@reldef@*/ STAILQ_HEAD(yasm_datavalhead, yasm_dataval); -#endif /** Set multiple field of a bytecode. * A bytecode can be repeated a number of times when output. This function @@ -143,15 +141,13 @@ void yasm_bc_set_multiple(yasm_bytecode *bc, /*@keep@*/ yasm_expr *e); /*@dependent@*/ /*@null@*/ yasm_section *yasm_bc_get_section (yasm_bytecode *bc); -#ifdef YASM_LIB_INTERNAL /** Add to the list of symrecs that reference a bytecode. For symrec use * only. * \param bc bytecode * \param sym symbol */ void yasm_bc__add_symrec(yasm_bytecode *bc, /*@dependent@*/ yasm_symrec *sym); -#endif - + /** Delete (free allocated memory for) a bytecode. * \param bc bytecode (only pointer to it); may be NULL */ @@ -313,9 +309,7 @@ yasm_dataval *yasm_dv_create_raw(/*@keep@*/ unsigned char *contents, * \param headp list of data values */ void yasm_dvs_initialize(yasm_datavalhead *headp); -#ifdef YASM_LIB_INTERNAL #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/errwarn.c b/libyasm/errwarn.c index b3a59c05..64b2f9eb 100644 --- a/libyasm/errwarn.c +++ b/libyasm/errwarn.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/expr.c b/libyasm/expr.c index 470184df..34800935 100644 --- a/libyasm/expr.c +++ b/libyasm/expr.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/floatnum.c b/libyasm/floatnum.c index cb0435fe..951e17ca 100644 --- a/libyasm/floatnum.c +++ b/libyasm/floatnum.c @@ -26,7 +26,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/hamt.c b/libyasm/hamt.c index 32e13035..dd28c544 100644 --- a/libyasm/hamt.c +++ b/libyasm/hamt.c @@ -29,7 +29,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/insn.c b/libyasm/insn.c index 7fc21c38..219a56c0 100644 --- a/libyasm/insn.c +++ b/libyasm/insn.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); @@ -292,19 +291,3 @@ yasm_insn_finalize(yasm_insn *insn) } } } - -/* Non-macro yasm_insn_ops_first() for non-YASM_LIB_INTERNAL users. */ -#undef yasm_insn_ops_first -yasm_insn_operand * -yasm_insn_ops_first(yasm_insn *insn) -{ - return STAILQ_FIRST(&insn->operands); -} - -/* Non-macro yasm_insn_op_next() for non-YASM_LIB_INTERNAL users. */ -#undef yasm_insn_op_next -yasm_insn_operand * -yasm_insn_op_next(yasm_insn_operand *cur) -{ - return STAILQ_NEXT(cur, link); -} diff --git a/libyasm/insn.h b/libyasm/insn.h index a12e1eff..20977b2c 100644 --- a/libyasm/insn.h +++ b/libyasm/insn.h @@ -69,7 +69,6 @@ struct yasm_effaddr { /** An instruction operand (opaque type). */ typedef struct yasm_insn_operand yasm_insn_operand; -#ifdef YASM_LIB_INTERNAL /** An instruction operand. */ struct yasm_insn_operand { /** Link for building linked list of operands. \internal */ @@ -137,7 +136,6 @@ struct yasm_insn { unsigned int num_prefixes; /**< Number of prefixes. */ unsigned int num_segregs; /**< Number of segment prefixes. */ }; -#endif /** Set segment override for an effective address. * Some architectures (such as x86) support segment overrides on effective @@ -178,17 +176,14 @@ yasm_insn_operand *yasm_operand_create_imm(/*@only@*/ yasm_expr *val); * \return First operand (NULL if no operands). */ yasm_insn_operand *yasm_insn_ops_first(yasm_insn *insn); +#define yasm_insn_ops_first(insn) STAILQ_FIRST(&((insn)->operands)) /** Get the next operand in an instruction. * \param op previous operand * \return Next operand (NULL if op was the last operand). */ yasm_insn_operand *yasm_insn_op_next(yasm_insn_operand *op); - -#if defined(YASM_LIB_INTERNAL) && !defined(YASM_DOXYGEN) -#define yasm_insn_ops_first(insn) STAILQ_FIRST(&(insn)->operands) #define yasm_insn_op_next(cur) STAILQ_NEXT(cur, link) -#endif /** Add operand to the end of an instruction. * \note Does not make a copy of the operand; so don't pass this function diff --git a/libyasm/intnum.c b/libyasm/intnum.c index 2132733f..0e3411f6 100644 --- a/libyasm/intnum.c +++ b/libyasm/intnum.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/inttree.c b/libyasm/inttree.c index 2c408f1c..382a5981 100644 --- a/libyasm/inttree.c +++ b/libyasm/inttree.c @@ -1,4 +1,3 @@ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/linemap.c b/libyasm/linemap.c index e2ff9300..b2c2d992 100644 --- a/libyasm/linemap.c +++ b/libyasm/linemap.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/mergesort.c b/libyasm/mergesort.c index bde5242e..a5b33da4 100644 --- a/libyasm/mergesort.c +++ b/libyasm/mergesort.c @@ -31,7 +31,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/phash.c b/libyasm/phash.c index 2ce1938d..21a8ad1c 100644 --- a/libyasm/phash.c +++ b/libyasm/phash.c @@ -1,5 +1,4 @@ /* Modified for use with yasm by Peter Johnson. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/section.c b/libyasm/section.c index 2b5d4342..b5fc6aed 100644 --- a/libyasm/section.c +++ b/libyasm/section.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/section.h b/libyasm/section.h index 27ccb298..ff18e331 100644 --- a/libyasm/section.h +++ b/libyasm/section.h @@ -39,13 +39,11 @@ */ typedef struct yasm_reloc yasm_reloc; -#ifdef YASM_LIB_INTERNAL struct yasm_reloc { /*@reldef@*/ STAILQ_ENTRY(yasm_reloc) link; yasm_intnum *addr; /**< Offset (address) within section */ /*@dependent@*/ yasm_symrec *sym; /**< Relocated symbol */ }; -#endif /** An object. This is the internal representation of an object file. */ struct yasm_object { @@ -62,7 +60,6 @@ struct yasm_object { */ /*@dependent@*/ /*@null@*/ yasm_section *cur_section; -#ifdef YASM_LIB_INTERNAL /** Linked list of sections. */ /*@reldef@*/ STAILQ_HEAD(yasm_sectionhead, yasm_section) sections; @@ -70,7 +67,6 @@ struct yasm_object { * second level is directive name. */ /*@owned@*/ struct HAMT *directives; -#endif }; /** Create a new object. A default section is created as the first section. @@ -256,10 +252,7 @@ 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); - -#ifdef YASM_LIB_INTERNAL #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/strcasecmp.c b/libyasm/strcasecmp.c index 66424c6b..69d87113 100644 --- a/libyasm/strcasecmp.c +++ b/libyasm/strcasecmp.c @@ -29,7 +29,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/strsep.c b/libyasm/strsep.c index f57c1b0a..7f538797 100644 --- a/libyasm/strsep.c +++ b/libyasm/strsep.c @@ -28,7 +28,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #define NO_STRING_INLINES #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/symrec.c b/libyasm/symrec.c index a28de475..91807eb4 100644 --- a/libyasm/symrec.c +++ b/libyasm/symrec.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/valparam.c b/libyasm/valparam.c index 752ab7e3..4a8a8183 100644 --- a/libyasm/valparam.c +++ b/libyasm/valparam.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); @@ -218,31 +217,6 @@ yasm_vps_destroy(yasm_valparamhead *headp) yasm_xfree(headp); } -/* Non-macro yasm_vps_append() for non-YASM_LIB_INTERNAL users. */ -#undef yasm_vps_append -void -yasm_vps_append(yasm_valparamhead *headp, /*@keep@*/ yasm_valparam *vp) -{ - if (vp) - STAILQ_INSERT_TAIL(headp, vp, link); -} - -/* Non-macro yasm_vps_first() for non-YASM_LIB_INTERNAL users. */ -#undef yasm_vps_first -/*@null@*/ /*@dependent@*/ yasm_valparam * -yasm_vps_first(yasm_valparamhead *headp) -{ - return STAILQ_FIRST(headp); -} - -/* Non-macro yasm_vps_next() for non-YASM_LIB_INTERNAL users. */ -#undef yasm_vps_next -/*@null@*/ /*@dependent@*/ yasm_valparam * -yasm_vps_next(yasm_valparam *cur) -{ - return STAILQ_NEXT(cur, link); -} - int yasm_dir_helper(void *obj, yasm_valparam *vp_first, unsigned long line, const yasm_dir_help *help, size_t nhelp, void *data, diff --git a/libyasm/valparam.h b/libyasm/valparam.h index 4a64a66f..d33a3cf6 100644 --- a/libyasm/valparam.h +++ b/libyasm/valparam.h @@ -34,7 +34,6 @@ #ifndef YASM_VALPARAM_H #define YASM_VALPARAM_H -#ifdef YASM_LIB_INTERNAL /** Value/parameter pair. \internal */ struct yasm_valparam { /*@reldef@*/ STAILQ_ENTRY(yasm_valparam) link; /**< Next pair in list */ @@ -63,7 +62,6 @@ struct yasm_valparam { /** Linked list of value/parameter pairs. \internal */ /*@reldef@*/ STAILQ_HEAD(yasm_valparamhead, yasm_valparam); -#endif /** Directive list entry structure. */ struct yasm_directive { @@ -166,10 +164,10 @@ yasm_valparamhead *yasm_vps_create(void); */ void yasm_vps_destroy(yasm_valparamhead *headp); -#ifdef YASM_LIB_INTERNAL /** Initialize linked list of valparams. * \param headp linked list */ +void yasm_vps_initialize(/*@out@*/ yasm_valparamhead *headp); #define yasm_vps_initialize(headp) STAILQ_INIT(headp) /** Destroy (free allocated memory for) linked list of valparams (created with @@ -178,19 +176,16 @@ void yasm_vps_destroy(yasm_valparamhead *headp); * \param headp linked list */ void yasm_vps_delete(yasm_valparamhead *headp); -#endif /** Append valparam to tail of linked list. * \param headp linked list * \param vp valparam */ void yasm_vps_append(yasm_valparamhead *headp, /*@keep@*/ yasm_valparam *vp); -#ifdef YASM_LIB_INTERNAL #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 @@ -198,16 +193,13 @@ void yasm_vps_append(yasm_valparamhead *headp, /*@keep@*/ yasm_valparam *vp); */ /*@null@*/ /*@dependent@*/ yasm_valparam *yasm_vps_first (yasm_valparamhead *headp); -#ifdef YASM_LIB_INTERNAL #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); -#ifdef YASM_LIB_INTERNAL #define yasm_vps_next(cur) STAILQ_NEXT(cur, link) /** Iterate through linked list of valparams. @@ -216,7 +208,6 @@ void yasm_vps_append(yasm_valparamhead *headp, /*@keep@*/ yasm_valparam *vp); * \param headp linked list */ #define yasm_vps_foreach(iter, headp) STAILQ_FOREACH(iter, headp, link) -#endif /** Print linked list of valparams. For debugging purposes. * \param f file diff --git a/libyasm/value.c b/libyasm/value.c index decaaff8..0a5936c7 100644 --- a/libyasm/value.c +++ b/libyasm/value.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" /*@unused@*/ RCSID("$Id$"); diff --git a/libyasm/xmalloc.c b/libyasm/xmalloc.c index 5430ddd5..d2cd2380 100644 --- a/libyasm/xmalloc.c +++ b/libyasm/xmalloc.c @@ -24,7 +24,6 @@ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" RCSID("$Id$"); diff --git a/libyasm/xstrdup.c b/libyasm/xstrdup.c index 83ac3955..b0bbdfd3 100644 --- a/libyasm/xstrdup.c +++ b/libyasm/xstrdup.c @@ -28,7 +28,6 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ -#define YASM_LIB_INTERNAL #include "util.h" RCSID("$Id$"); diff --git a/modules/arch/lc3b/lc3barch.c b/modules/arch/lc3b/lc3barch.c index aad37108..152f6f1f 100644 --- a/modules/arch/lc3b/lc3barch.c +++ b/modules/arch/lc3b/lc3barch.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "lc3barch.h" diff --git a/modules/arch/lc3b/lc3bbc.c b/modules/arch/lc3b/lc3bbc.c index 95478897..f864b328 100644 --- a/modules/arch/lc3b/lc3bbc.c +++ b/modules/arch/lc3b/lc3bbc.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/arch/lc3b/lc3bid.re b/modules/arch/lc3b/lc3bid.re index dcd6599d..47c94644 100644 --- a/modules/arch/lc3b/lc3bid.re +++ b/modules/arch/lc3b/lc3bid.re @@ -27,7 +27,6 @@ #include RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/arch/x86/x86arch.c b/modules/arch/x86/x86arch.c index ba323185..0f8c9527 100644 --- a/modules/arch/x86/x86arch.c +++ b/modules/arch/x86/x86arch.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "x86arch.h" diff --git a/modules/arch/x86/x86bc.c b/modules/arch/x86/x86bc.c index ade330e2..cff6e583 100644 --- a/modules/arch/x86/x86bc.c +++ b/modules/arch/x86/x86bc.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/arch/x86/x86expr.c b/modules/arch/x86/x86expr.c index 2ad101c0..ae99f7d2 100644 --- a/modules/arch/x86/x86expr.c +++ b/modules/arch/x86/x86expr.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/arch/x86/x86id.c b/modules/arch/x86/x86id.c index 76b621be..ce26da38 100644 --- a/modules/arch/x86/x86id.c +++ b/modules/arch/x86/x86id.c @@ -28,7 +28,6 @@ #include RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/dbgfmts/codeview/cv-dbgfmt.c b/modules/dbgfmts/codeview/cv-dbgfmt.c index 75dc2f1e..2cb23255 100644 --- a/modules/dbgfmts/codeview/cv-dbgfmt.c +++ b/modules/dbgfmts/codeview/cv-dbgfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/dbgfmts/codeview/cv-symline.c b/modules/dbgfmts/codeview/cv-symline.c index f9ddd992..6ad141a1 100644 --- a/modules/dbgfmts/codeview/cv-symline.c +++ b/modules/dbgfmts/codeview/cv-symline.c @@ -30,7 +30,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/dbgfmts/codeview/cv-type.c b/modules/dbgfmts/codeview/cv-type.c index 9722a414..433013ea 100644 --- a/modules/dbgfmts/codeview/cv-type.c +++ b/modules/dbgfmts/codeview/cv-type.c @@ -30,7 +30,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/dbgfmts/dwarf2/dwarf2-aranges.c b/modules/dbgfmts/dwarf2/dwarf2-aranges.c index 34ff80e1..0df37b56 100644 --- a/modules/dbgfmts/dwarf2/dwarf2-aranges.c +++ b/modules/dbgfmts/dwarf2/dwarf2-aranges.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "dwarf2-dbgfmt.h" diff --git a/modules/dbgfmts/dwarf2/dwarf2-dbgfmt.c b/modules/dbgfmts/dwarf2/dwarf2-dbgfmt.c index b0469c32..e889f51f 100644 --- a/modules/dbgfmts/dwarf2/dwarf2-dbgfmt.c +++ b/modules/dbgfmts/dwarf2/dwarf2-dbgfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/dbgfmts/dwarf2/dwarf2-info.c b/modules/dbgfmts/dwarf2/dwarf2-info.c index 433b93ef..be6cf605 100644 --- a/modules/dbgfmts/dwarf2/dwarf2-info.c +++ b/modules/dbgfmts/dwarf2/dwarf2-info.c @@ -34,7 +34,6 @@ #include #endif -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/dbgfmts/dwarf2/dwarf2-line.c b/modules/dbgfmts/dwarf2/dwarf2-line.c index 6e77ceb4..90dc7ea9 100644 --- a/modules/dbgfmts/dwarf2/dwarf2-line.c +++ b/modules/dbgfmts/dwarf2/dwarf2-line.c @@ -30,7 +30,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/dbgfmts/null/null-dbgfmt.c b/modules/dbgfmts/null/null-dbgfmt.c index d3f5fd13..1cf5f642 100644 --- a/modules/dbgfmts/null/null-dbgfmt.c +++ b/modules/dbgfmts/null/null-dbgfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include diff --git a/modules/dbgfmts/stabs/stabs-dbgfmt.c b/modules/dbgfmts/stabs/stabs-dbgfmt.c index a3fe8277..ad25581a 100644 --- a/modules/dbgfmts/stabs/stabs-dbgfmt.c +++ b/modules/dbgfmts/stabs/stabs-dbgfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/listfmts/nasm/nasm-listfmt.c b/modules/listfmts/nasm/nasm-listfmt.c index 21ce4330..8b550435 100644 --- a/modules/listfmts/nasm/nasm-listfmt.c +++ b/modules/listfmts/nasm/nasm-listfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #include diff --git a/modules/objfmts/bin/bin-objfmt.c b/modules/objfmts/bin/bin-objfmt.c index 496c412b..cf06d50b 100644 --- a/modules/objfmts/bin/bin-objfmt.c +++ b/modules/objfmts/bin/bin-objfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/objfmts/coff/coff-objfmt.c b/modules/objfmts/coff/coff-objfmt.c index bd856140..cb4719de 100644 --- a/modules/objfmts/coff/coff-objfmt.c +++ b/modules/objfmts/coff/coff-objfmt.c @@ -28,7 +28,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/objfmts/coff/win64-except.c b/modules/objfmts/coff/win64-except.c index 99c14376..82b5f616 100644 --- a/modules/objfmts/coff/win64-except.c +++ b/modules/objfmts/coff/win64-except.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/objfmts/dbg/dbg-objfmt.c b/modules/objfmts/dbg/dbg-objfmt.c index e1aad7ad..8452a810 100644 --- a/modules/objfmts/dbg/dbg-objfmt.c +++ b/modules/objfmts/dbg/dbg-objfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include diff --git a/modules/objfmts/elf/elf-objfmt.c b/modules/objfmts/elf/elf-objfmt.c index d53e2430..ecf13f40 100644 --- a/modules/objfmts/elf/elf-objfmt.c +++ b/modules/objfmts/elf/elf-objfmt.c @@ -44,7 +44,6 @@ * Each Section is spatially disjoint, and has exactly one SHT entry. */ -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/objfmts/elf/elf-x86-amd64.c b/modules/objfmts/elf/elf-x86-amd64.c index c1318d64..559fb50c 100644 --- a/modules/objfmts/elf/elf-x86-amd64.c +++ b/modules/objfmts/elf/elf-x86-amd64.c @@ -28,7 +28,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_EXPR_INTERNAL #include #define YASM_OBJFMT_ELF_INTERNAL diff --git a/modules/objfmts/elf/elf-x86-x86.c b/modules/objfmts/elf/elf-x86-x86.c index 00d7a047..d639b599 100644 --- a/modules/objfmts/elf/elf-x86-x86.c +++ b/modules/objfmts/elf/elf-x86-x86.c @@ -28,7 +28,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_EXPR_INTERNAL #include #define YASM_OBJFMT_ELF_INTERNAL diff --git a/modules/objfmts/elf/elf.c b/modules/objfmts/elf/elf.c index 3bcbffb5..e3b23276 100644 --- a/modules/objfmts/elf/elf.c +++ b/modules/objfmts/elf/elf.c @@ -28,7 +28,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_EXPR_INTERNAL #include #define YASM_OBJFMT_ELF_INTERNAL diff --git a/modules/objfmts/macho/macho-objfmt.c b/modules/objfmts/macho/macho-objfmt.c index ceddbf98..507279e0 100644 --- a/modules/objfmts/macho/macho-objfmt.c +++ b/modules/objfmts/macho/macho-objfmt.c @@ -108,7 +108,6 @@ /* optional: automatically prefix underscores to global exported symbols */ /*#define AUTO_UNDERSCORE*/ -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/objfmts/rdf/rdf-objfmt.c b/modules/objfmts/rdf/rdf-objfmt.c index 124f2560..64047915 100644 --- a/modules/objfmts/rdf/rdf-objfmt.c +++ b/modules/objfmts/rdf/rdf-objfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/objfmts/xdf/xdf-objfmt.c b/modules/objfmts/xdf/xdf-objfmt.c index 84e0e314..a0c58848 100644 --- a/modules/objfmts/xdf/xdf-objfmt.c +++ b/modules/objfmts/xdf/xdf-objfmt.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_BC_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/parsers/gas/gas-parse.c b/modules/parsers/gas/gas-parse.c index 8cbe4350..6e79ec1c 100644 --- a/modules/parsers/gas/gas-parse.c +++ b/modules/parsers/gas/gas-parse.c @@ -30,7 +30,6 @@ #include RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/parsers/gas/gas-parser.c b/modules/parsers/gas/gas-parser.c index e2515341..16c792bd 100644 --- a/modules/parsers/gas/gas-parser.c +++ b/modules/parsers/gas/gas-parser.c @@ -30,7 +30,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "gas-parser.h" diff --git a/modules/parsers/gas/gas-token.re b/modules/parsers/gas/gas-token.re index 6cd6cd02..457eee0e 100644 --- a/modules/parsers/gas/gas-token.re +++ b/modules/parsers/gas/gas-token.re @@ -30,7 +30,6 @@ #include RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "modules/parsers/gas/gas-parser.h" diff --git a/modules/parsers/nasm/nasm-parse.c b/modules/parsers/nasm/nasm-parse.c index 2943cf9c..5ef7c11f 100644 --- a/modules/parsers/nasm/nasm-parse.c +++ b/modules/parsers/nasm/nasm-parse.c @@ -27,7 +27,6 @@ #include RCSID("$Id$"); -#define YASM_LIB_INTERNAL #define YASM_EXPR_INTERNAL #include diff --git a/modules/parsers/nasm/nasm-parser.c b/modules/parsers/nasm/nasm-parser.c index 2fa1934b..8cdc63a0 100644 --- a/modules/parsers/nasm/nasm-parser.c +++ b/modules/parsers/nasm/nasm-parser.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "nasm-parser.h" diff --git a/modules/parsers/nasm/nasm-token.re b/modules/parsers/nasm/nasm-token.re index 0a56073a..de58cf0e 100644 --- a/modules/parsers/nasm/nasm-token.re +++ b/modules/parsers/nasm/nasm-token.re @@ -29,7 +29,6 @@ #include RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "modules/parsers/nasm/nasm-parser.h" diff --git a/modules/preprocs/nasm/nasm-preproc.c b/modules/preprocs/nasm/nasm-preproc.c index 58f5a2f5..96700267 100644 --- a/modules/preprocs/nasm/nasm-preproc.c +++ b/modules/preprocs/nasm/nasm-preproc.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "nasm.h" diff --git a/modules/preprocs/raw/raw-preproc.c b/modules/preprocs/raw/raw-preproc.c index f58856c3..4e80cfff 100644 --- a/modules/preprocs/raw/raw-preproc.c +++ b/modules/preprocs/raw/raw-preproc.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include diff --git a/modules/preprocs/yapp/yapp-preproc.c b/modules/preprocs/yapp/yapp-preproc.c index 4f7767ac..c7756442 100644 --- a/modules/preprocs/yapp/yapp-preproc.c +++ b/modules/preprocs/yapp/yapp-preproc.c @@ -27,7 +27,6 @@ #include /*@unused@*/ RCSID("$Id$"); -#define YASM_LIB_INTERNAL #include #include "yapp-preproc.h"