mirror of
https://github.com/netwide-assembler/nasm.git
synced 2025-03-19 18:00:23 +08:00
Putting WARN_OTHER at the end of the list creates a number of advantages and simplifications: 1. It is more user friendly! It is far more of a logical location for the default case to be at the end of the printed list. 2. The value 0 can be used in a number of places to indicate a non-suppressible event. By having warning_state[0] always contain WARN_ST_ENABLED, we can always do the table lookup, even. 3. It means non-warnings (except fatal/panic) can now be conditioned on warning states. In those cases, WARN_*, including WARN_OTHER, can be added to the mask for any category. This is especially useful for notes. The only downside is that we have to explicitly detect the case where we have ERR_WARNING but no WARN_ flag. This is a trivial test. Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>