The NetBSD Project

CVS log for src/usr.bin/xlint/lint1/check-msgs.lua

[BACK] Up to [cvs.NetBSD.org] / src / usr.bin / xlint / lint1

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.21 / (download) - annotate - [select for diffs], Tue Feb 6 22:47:21 2024 UTC (3 weeks, 1 day ago) by rillig
Branch: MAIN
CVS Tags: HEAD
Changes since 1.20: +2 -2 lines
Diff to previous 1.20 (colored)

lint: tab-align message numbers in err.c

By replacing block comments with end-of-line comments, the comments take
up less space and thus no longer require to be indented by 6 spaces.

The messages and their comments are used in 3 places: the manual page
lint.7, the err-msgs.h header for debug mode, and check-msgs.lua to
verify that the comments above the message IDs correspond to the actual
messages.

No functional change.

Revision 1.20 / (download) - annotate - [select for diffs], Sat Aug 12 18:05:51 2023 UTC (6 months, 2 weeks ago) by rillig
Branch: MAIN
Changes since 1.19: +18 -1 lines
Diff to previous 1.19 (colored)

lint: clean up

Revision 1.19 / (download) - annotate - [select for diffs], Mon Jul 10 11:46:14 2023 UTC (7 months, 3 weeks ago) by rillig
Branch: MAIN
Changes since 1.18: +31 -1 lines
Diff to previous 1.18 (colored)

lint: ensure that untyped grammar rules are listed

Untyped grammar rules are suspicious because they subtly affect the
order in which the grammar actions are performed.  This leads to the
various bugs mentioned in msg_347.c.

Revision 1.18 / (download) - annotate - [select for diffs], Sun Jul 2 23:40:23 2023 UTC (7 months, 4 weeks ago) by rillig
Branch: MAIN
Changes since 1.17: +2 -1 lines
Diff to previous 1.17 (colored)

lint: add initial support for C23

Required by xsrc/external/mit/MesaLib.old, brw_eu_validate.c, which
initializes a struct using empty braces: 'return (struct string){};'.

Revision 1.17 / (download) - annotate - [select for diffs], Tue Jul 5 22:50:41 2022 UTC (19 months, 3 weeks ago) by rillig
Branch: MAIN
CVS Tags: netbsd-10-base, netbsd-10-0-RC5, netbsd-10-0-RC4, netbsd-10-0-RC3, netbsd-10-0-RC2, netbsd-10-0-RC1, netbsd-10
Changes since 1.16: +14 -11 lines
Diff to previous 1.16 (colored)

lint: add additional queries that are not enabled by default

In the last 18 months, several lint warnings have been made adjusted to
allow common usage patterns.  For example, lint no longer warns about a
constant condition in the statement 'do { ... } while (false)' (message
161), as this pattern is well-known in statement-like macros, making it
unlikely that the 'false' is a mistake.  Another example is casts
between unequal pointer types (message 247) for a few well-known
patterns that are unlikely to be bugs.

Occasionally, it is useful to query the code for patterns or events that
would not justify a warning.  These patterns are modeled as predefined
queries that can be selected individually, in addition to and
independently of the existing warnings and errors.

New queries can be added as needed, in the same way as new warnings.
Queries that are deemed no longer used can be deactivated in the same
way as warnings that are no longer used.

As long as none of the queries is enabled, they produce a minimal
overhead of querying a single global variable.  Computations that are
more expensive than a few machine instructions should be guarded by
any_query_enabled.

https://mail-index.netbsd.org/source-changes-d/2022/06/28/msg013716.html

ok christos@

Revision 1.16 / (download) - annotate - [select for diffs], Sun Jul 3 21:17:24 2022 UTC (19 months, 3 weeks ago) by rillig
Branch: MAIN
Changes since 1.15: +11 -12 lines
Diff to previous 1.15 (colored)

lint: do not treat message IDs as arithmetic numbers

No functional change.

Revision 1.15 / (download) - annotate - [select for diffs], Sun Jul 3 20:05:46 2022 UTC (19 months, 3 weeks ago) by rillig
Branch: MAIN
Changes since 1.14: +1 -8 lines
Diff to previous 1.14 (colored)

lint: remove unused code in consistency checker

Revision 1.14 / (download) - annotate - [select for diffs], Sun Jul 3 07:33:08 2022 UTC (19 months, 4 weeks ago) by rillig
Branch: MAIN
Changes since 1.13: +13 -6 lines
Diff to previous 1.13 (colored)

lint: verify that comment above warning_at matches the message

No binary change.

Revision 1.13 / (download) - annotate - [select for diffs], Thu Dec 16 21:14:58 2021 UTC (2 years, 2 months ago) by rillig
Branch: MAIN
Changes since 1.12: +15 -6 lines
Diff to previous 1.12 (colored)

tests/lint: ensure that tests on a message mention this message

Revision 1.12 / (download) - annotate - [select for diffs], Sat Sep 4 12:30:46 2021 UTC (2 years, 5 months ago) by rillig
Branch: MAIN
Changes since 1.11: +2 -18 lines
Diff to previous 1.11 (colored)

lint: spell out abbreviations in comments

No functional change.

Revision 1.11 / (download) - annotate - [select for diffs], Tue Jun 15 08:37:56 2021 UTC (2 years, 8 months ago) by rillig
Branch: MAIN
Changes since 1.10: +23 -34 lines
Diff to previous 1.10 (colored)

tests/lint1: make error handling in the lint1 linter simpler

Revision 1.10 / (download) - annotate - [select for diffs], Wed Apr 14 18:35:40 2021 UTC (2 years, 10 months ago) by rillig
Branch: MAIN
CVS Tags: cjep_sun2x-base1, cjep_sun2x-base, cjep_sun2x, cjep_staticlib_x-base1, cjep_staticlib_x-base, cjep_staticlib_x
Changes since 1.9: +3 -2 lines
Diff to previous 1.9 (colored)

lint: add support for C11-isms such as int[static 3]

Revision 1.9 / (download) - annotate - [select for diffs], Sun Feb 28 12:45:47 2021 UTC (3 years ago) by rillig
Branch: MAIN
Changes since 1.8: +3 -8 lines
Diff to previous 1.8 (colored)

tests/lint: shorten code for checking redundancy in files

No functional change.

Revision 1.8 / (download) - annotate - [select for diffs], Sun Feb 28 12:40:00 2021 UTC (3 years ago) by rillig
Branch: MAIN
Changes since 1.7: +36 -1 lines
Diff to previous 1.7 (colored)

tests/lint: keep messages in test files in sync with actual messages

Each of the tests named msg_*.c repeats the template of the message, to
make the test somewhat self-contained when viewed in isolation.

This creates a redundancy, and keeping track of this manually is next to
impossible.  I tried it and failed in 9 cases, even though it has just
been 2 months since I myself created the initial files and I knew all
the time that this redundancy exists.

Be fool-proof for the future by checking this automatically.

Revision 1.7 / (download) - annotate - [select for diffs], Fri Feb 19 23:22:19 2021 UTC (3 years ago) by rillig
Branch: MAIN
Changes since 1.6: +21 -20 lines
Diff to previous 1.6 (colored)

lint: shorten code in check-msgs.lua

No functional change.

Revision 1.6 / (download) - annotate - [select for diffs], Sun Jan 31 11:44:48 2021 UTC (3 years ago) by rillig
Branch: MAIN
Changes since 1.5: +1 -2 lines
Diff to previous 1.5 (colored)

lint: mention the operator in messages about bit shifts

Revision 1.5 / (download) - annotate - [select for diffs], Sat Jan 2 01:12:38 2021 UTC (3 years, 1 month ago) by rillig
Branch: MAIN
Changes since 1.4: +5 -4 lines
Diff to previous 1.4 (colored)

lint: fix typo in check-msgs tool

Revision 1.4 / (download) - annotate - [select for diffs], Fri Jan 1 11:41:01 2021 UTC (3 years, 1 month ago) by rillig
Branch: MAIN
Changes since 1.3: +7 -2 lines
Diff to previous 1.3 (colored)

lint: add missing redundant messages in source code

Revision 1.3 / (download) - annotate - [select for diffs], Fri Jan 1 01:26:02 2021 UTC (3 years, 1 month ago) by rillig
Branch: MAIN
Changes since 1.2: +6 -6 lines
Diff to previous 1.2 (colored)

lint: align comments with actual message, in the lexer and parser

Revision 1.2 / (download) - annotate - [select for diffs], Fri Jan 1 00:00:24 2021 UTC (3 years, 1 month ago) by rillig
Branch: MAIN
Changes since 1.1: +20 -4 lines
Diff to previous 1.1 (colored)

lint: align comments in code with actual messages

Redundancy is bad.  Especially in this case, separating the format
strings from the actual arguments prevents the compiler from
cross-checking them.

Revision 1.1 / (download) - annotate - [select for diffs], Thu Dec 31 22:48:33 2020 UTC (3 years, 1 month ago) by rillig
Branch: MAIN

lint: check messages and their IDs for consistency

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>