Look at the following code:
segment .text
mov eax, x
mov ebx, y
...
segment .data
x DW 10
y DW 1
It has a bug: 'x' and 'y' are defined with 'dw' (16 bits) instead of 'dd' (32 bits). And they're assigned to 32 bits registers.
How can I make NASM print a warning in this case? If it's not possible, is there some way to guard against such bugs?
I've run nasm with the '-w+all' command line option, but it prints no warning.
(I'm new to Assembly.)