Up to [cvs.NetBSD.org] / src / tests / usr.bin / xlint / lint1
Request diff between arbitrary revisions
Keyword substitution: kv
Default branch: MAIN
tests/lint: remove .exp files, as they have become redundant Now that each lint1 test lists all generated diagnostics as 'expect' comments, the information from the .exp files is no longer needed. The only information that gets lost is the order of the diagnostics, which is mostly relevant for paired messages like 'inconsistent definition' + 'previous definition was here'.
lint: improve determination of abstract typename Still not perfect, but at least a step in the right direction. See decl_direct_abstract.c for the missing edge cases. See PR#22119.
tests/lint: expect complete messages in feature tests Previously, the tests contained many comments like /* expect: 123 */, which were useless to a casual reader since nobody is expected to learn lint's message IDs by heart. Replace these with the complete diagnostics, to show what lint is complaining about. The tests named msg_*.c have been left unmodified since they mention the full message text in their header comment. No functional change.
lint: add quotes around placeholder in message about undefined variable Before: error: expected undefined [99] After: error: 'expected' undefined [99] Seen in external/mpl/bind, which for Clang defines in stdatomic.h: > #define atomic_exchange_explicit(obj, desired, order) \ > __c11_atomic_exchange_explicit(obj, expected, order) Note the mismatch between 'desired' and 'expected'.
lint: prefix error messages with 'error:' This makes it easier to find these errors in the build logs.
lint: fix null pointer dereference on parse error Fixes PR bin/22119.