Sun Studio 12: C User's Guide

4.4.1 Options to Suppress Messages

You can use several lint options to suppress lint diagnostic messages. Messages can be suppressed with the -erroff option, followed by one or more tags. These mnemonic tags can be displayed with the -errtags=yes option.

The following table lists the options that suppress lint messages.

Table 4–8 lint Options to Suppress Messages


Messages Suppressed  


assignment causes implicit narrowing conversion

conversion to larger integral type may sign-extend incorrectly


statement not reached (unreachable break and empty statements)


assignment operator "=" found where equality operator "==" was expected

constant operand to op: "!"

fallthrough on case statements

pointer cast may result in improper alignment

precedence confusion possible; parenthesize

statement has no consequent: if

statement has no consequent: else


declared global, could be static


One or more lint messages specified by tag


name defined but never used

name used but not defined


arguments unused in function


name declared but never used or defined