mirror of
https://github.com/netwide-assembler/nasm.git
synced 2025-04-24 19:00:23 +08:00
insnsd.c: don't generate an inaccessible table
Some pseudo-instructions (RESB and EQU) seem to make it into the instruction table. This also generates an instruction table for zero-length instructions, which of course can never actually be accessed. Quiet a compiler warning by simply not emitting this useless table. Ideally we shouldn't emit the pseudo-instructions either, but that is a bigger change, and it's hardly a lot of memory involved.
This commit is contained in:
parent
b2072eacd3
commit
cb6aaa33ce
1
insns.pl
1
insns.pl
@ -184,6 +184,7 @@ if ( !defined($output) || $output eq 'd' ) {
|
||||
print D "};\n";
|
||||
|
||||
foreach $h (sort(keys(%dinstables))) {
|
||||
next if ($h eq ''); # Skip pseudo-instructions
|
||||
print D "\nstatic const struct itemplate * const itable_${h}[] = {\n";
|
||||
foreach $j (@{$dinstables{$h}}) {
|
||||
print D " instrux + $j,\n";
|
||||
|
Loading…
x
Reference in New Issue
Block a user