summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2008-07-19 21:44:26 -0700
committerH. Peter Anvin <hpa@zytor.com>2008-07-19 21:44:26 -0700
commita70547f3ae6abaa2c658fdfdacf0ad6001b6839f (patch)
tree19bb03d5498fbd6581504b64d2e8289ba94ad657
parent289ff7e2a870c8e29ebbbd9b3a04abcafd0643f4 (diff)
downloadnasm-a70547f3ae6abaa2c658fdfdacf0ad6001b6839f.tar.gz
nasm-a70547f3ae6abaa2c658fdfdacf0ad6001b6839f.tar.bz2
nasm-a70547f3ae6abaa2c658fdfdacf0ad6001b6839f.zip
Avoid redundant "const" for macros_t
Don't use a redundant "const" for macros_t (which is const unsigned char), since OpenWatcom doesn't like it, and I believe it is incorrect per the C standard.
-rw-r--r--nasm.h2
-rw-r--r--preproc.c8
-rw-r--r--preproc.h2
3 files changed, 6 insertions, 6 deletions
diff --git a/nasm.h b/nasm.h
index 4799e91..c34d7f0 100644
--- a/nasm.h
+++ b/nasm.h
@@ -751,7 +751,7 @@ struct ofmt {
* and user-level equivalents for any format-specific
* directives).
*/
- const macros_t *stdmac;
+ macros_t *stdmac;
/*
* This procedure is called at the start of an output session.
diff --git a/preproc.c b/preproc.c
index ee55b9f..b0fbaad 100644
--- a/preproc.c
+++ b/preproc.c
@@ -368,13 +368,13 @@ static uint64_t nested_rep_count;
* The standard macro set: defined in macros.c in the array nasm_stdmac.
* This gives our position in the macro set, when we're processing it.
*/
-static const macros_t *stdmacpos;
+static macros_t *stdmacpos;
/*
* The extra standard macros that come from the object format, if
* any.
*/
-static const macros_t *extrastdmac = NULL;
+static macros_t *extrastdmac = NULL;
static bool any_extrastdmac;
/*
@@ -2258,7 +2258,7 @@ static int do_directive(Token * tline)
case PP_USE:
{
- static const macros_t *use_pkg;
+ static macros_t *use_pkg;
const char *pkg_macro;
t = tline->next = expand_smacro(tline->next);
@@ -4509,7 +4509,7 @@ void pp_runtime(char *definition)
}
-void pp_extra_stdmac(const macros_t *macros)
+void pp_extra_stdmac(macros_t *macros)
{
extrastdmac = macros;
}
diff --git a/preproc.h b/preproc.h
index ff1e371..3b71923 100644
--- a/preproc.h
+++ b/preproc.h
@@ -23,6 +23,6 @@ void pp_pre_include(char *);
void pp_pre_define(char *);
void pp_pre_undefine(char *);
void pp_runtime(char *);
-void pp_extra_stdmac(const macros_t *);
+void pp_extra_stdmac(macros_t *);
#endif