summaryrefslogtreecommitdiff
path: root/asm/directiv.c
diff options
context:
space:
mode:
authorH. Peter Anvin (Intel) <hpa@zytor.com>2018-12-13 21:53:31 -0800
committerH. Peter Anvin (Intel) <hpa@zytor.com>2018-12-13 21:53:31 -0800
commit723ab481a6550454a6f834bb854e751744ca340a (patch)
treecb217692a76d3dcab83c7ad922e3adca9006dccd /asm/directiv.c
parent6bde2ed8806b3e53657d46b61ee79d7afe5c2e13 (diff)
downloadnasm-723ab481a6550454a6f834bb854e751744ca340a.tar.gz
warnings: define warning classes at point of usemkwarnings
It is extremely desirable to allow the user fine-grained control of warnings, but this has been complicated by the fact that a warning class has had to be defined in no less than three places (error.h, error.c, nasmdoc.src) before it can be used in source code. Instead, use a script to define these via magic comments at the point of use. This hopefully will encourage creating new classes as needed. Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>
Diffstat (limited to 'asm/directiv.c')
-rw-r--r--asm/directiv.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/asm/directiv.c b/asm/directiv.c
index 90b8b7b2..66901530 100644
--- a/asm/directiv.c
+++ b/asm/directiv.c
@@ -435,9 +435,7 @@ bool process_directives(char *directive)
}
case D_WARNING: /* [WARNING {+|-|*}warn-name] */
- if (!set_warning_status(value)) {
- nasm_warnf(WARN_UNK_WARNING, "unknown warning option: %s", value);
- }
+ set_warning_status(value);
break;
case D_CPU: /* [CPU] */