aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin (Intel) <hpa@zytor.com>2019-08-09 03:55:29 -0700
committerH. Peter Anvin (Intel) <hpa@zytor.com>2019-08-09 03:55:29 -0700
commit524918394d3fd4c2fb03cc01c015c96403524365 (patch)
tree530d801cfcfdd2fa8f874e931ac684210abe0a24
parentb1e15f42feb65e2401776450843cf23aab7895d4 (diff)
downloadnasm-524918394d3fd4c2fb03cc01c015c96403524365.tar.gz
nasm-524918394d3fd4c2fb03cc01c015c96403524365.tar.xz
nasm-524918394d3fd4c2fb03cc01c015c96403524365.zip
labels.c: don't use ERR_NOTE for additional information
ERR_NOTE just confuses things, especially in the case of a suppressed warning. The preprocessor doesn't use it for unwinding macros, either. Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>
-rw-r--r--asm/labels.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/asm/labels.c b/asm/labels.c
index 7527156d..f973d7ed 100644
--- a/asm/labels.c
+++ b/asm/labels.c
@@ -501,7 +501,7 @@ void define_label(const char *label, int32_t segment,
*/
if (changed) {
nasm_nonfatal("label `%s' inconsistently redefined", lptr->defn.label);
- noteflags = ERR_NOTE|ERR_HERE;
+ noteflags = ERR_NONFATAL|ERR_HERE|ERR_NO_SEVERITY;
} else {
/*!
*!label-redef [off] label redefined to an identical value
@@ -510,14 +510,13 @@ void define_label(const char *label, int32_t segment,
*! define the same label more than once to \e{different} values.
*/
nasm_warn(WARN_LABEL_REDEF,
- "label `%s' redefined to an identical value", lptr->defn.label);
- noteflags = ERR_NOTE|ERR_HERE|WARN_LABEL_REDEF;
+ "info: label `%s' redefined to an identical value", lptr->defn.label);
+ noteflags = ERR_WARNING|ERR_HERE|ERR_NO_SEVERITY|WARN_LABEL_REDEF;
}
src_get(&saved_line, &saved_fname);
src_set(lptr->defn.def_line, lptr->defn.def_file);
- nasm_error(noteflags, "label `%s' originally defined",
- lptr->defn.label);
+ nasm_error(noteflags, "info: label `%s' originally defined", lptr->defn.label);
src_set(saved_line, saved_fname);
} else if (changed && pass_final() && lptr->defn.type != LBL_SPECIAL) {
/*!