Copyright (C) 2000-2012 |
GNU Info (nasm.info)Section 2.1.182.1.18. The `-w' Option: Enable or Disable Assembly Warnings ------------------------------------------------------------ NASM can observe many conditions during the course of assembly which are worth mentioning to the user, but not a sufficiently severe error to justify NASM refusing to generate an output file. These conditions are reported like errors, but come up with the word `warning' before the message. Warnings do not prevent NASM from generating an output file and returning a success status to the operating system. Some conditions are even less severe than that: they are only sometimes worth mentioning to the user. Therefore NASM supports the `-w' command-line option, which enables or disables certain classes of assembly warning. Such warning classes are described by a name, for example `orphan-labels'; you can enable warnings of this class by the command- line option `-w+orphan-labels' and disable it by `-w-orphan-labels'. The suppressible warning classes are: * `macro-params' covers warnings about multi-line macros being invoked with the wrong number of parameters. This warning class is enabled by default; see *Note Section 4.3.1:: for an example of why you might want to disable it. * `macro-selfref' warns if a macro references itself. This warning class is enabled by default. * `orphan-labels' covers warnings about source lines which contain no instruction but define a label without a trailing colon. NASM does not warn about this somewhat obscure condition by default; see *Note Section 3.1:: for an example of why you might want it to. * `number-overflow' covers warnings about numeric constants which don't fit in 32 bits (for example, it's easy to type one too many Fs and produce `0x7ffffffff' by mistake). This warning class is enabled by default. * `gnu-elf-extensions' warns if 8-bit or 16-bit relocations are used in `-f elf' format. The GNU extensions allow this. This warning class is enabled by default. * In addition, warning classes may be enabled or disabled across sections of source code with `[warning +warning-name]' or `[warning -warning-name]'. No "user form" (without the brackets) exists. automatically generated by info2www version 1.2.2.9 |