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'.
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: in code from included files, print stack trace Previously, the standard NetBSD build generated several lint warnings in lhash.h from OpenSSL, without providing any hint as to which file actually included that header. In cases like these, lint now interprets the line number information in the preprocessor output from GCC to reconstruct the exact include path to the file in question. The program check-expect.lua had to be rewritten almost completely since it assumed that all diagnostics would come from the main file. In all existing tests, this was true, but these tests did not cover all cases that occurred in practice. Now it records the complete location of the diagnostic instead of just the line number.