Home | History | Annotate | Download | only in lint1
History log of /src/usr.bin/xlint/lint1/ckgetopt.c
RevisionDateAuthorComments
 1.28  27-Feb-2025  rillig lint: allow the getopt warning to be suppressed in the natural place
 1.27  19-Mar-2024  rillig branches: 1.27.2;
lint: keep invalid arguments in function calls

Previously, arguments of incomplete type or 'void' cleared all arguments
of the function call expression, requiring extra checks in later checks.

Invalid function calls are now exported to the .ln files, but that's
irrelevant in practice as these invalid function calls make lint1 fail,
after which xlint removes the .ln file.
 1.26  09-Mar-2024  rillig lint: inline accessor macros for tnode_t
 1.25  03-Mar-2024  rillig lint: clean up string parsing and snprintb check
 1.24  01-Mar-2024  rillig lint: fix misleading initializer for string iterator

The field 'start' marks the start of the previous matching character,
not the current iterator position.

No binary change.
 1.23  05-Feb-2024  rillig lint: make function call arguments directly accessible

Previously, the arguments of a function call expression were arranged in
a linear tree structure, from right to left. To allow easier access to
the arguments, store them in an array instead.
 1.22  03-Feb-2024  rillig lint: keep strings in their source representation

This allows further analysis depending on whether individual characters are
escaped as octal, hexadecimal or not at all.
 1.21  03-Feb-2024  rillig lint: clean up comments, reduce scope of variables
 1.20  01-Feb-2024  rillig lint: use standard buffer for storing string values

No functional change.
 1.19  29-Jan-2024  rillig lint: do not remember content of wide string literals

The plain char literals are needed for checking printf/scanf format
strings; lint has no similar check for wide strings. These format
strings are checked by modern compilers, making this check less
relevant.
 1.18  29-Jan-2024  rillig lint: check getopt call more strictly

Previously, '(c = getopt(...)) != -2' would match as well.
 1.17  03-Dec-2023  rillig lint: re-wrap comments

No functional change.
 1.16  20-May-2022  rillig lint: use __RCSID in lint mode as well

Since 1995-10-02, lint supports __asm statements and __asm modifiers.

No binary change.
 1.15  27-Feb-2022  rillig lint: merge duplicate code for handling plain and wide strings

No functional change. As before, the string literals "1" "2" "3" are
not concatenated from left to right, instead concatenation starts with
"23" and then proceeds to "123".
 1.14  01-Nov-2021  rillig lint: enter full C90 compatibility mode

The C99 comment in tree.c:3468 has been there since 2017-03-06, without
anyone complaining that their compiler would not handle it.

Strangely, running GCC 10.3.0 in '-std=c90' mode does not complain about
declarations after statements, '-Wdeclaration-after-statement' is needed
separately.

No functional change.
 1.13  01-Nov-2021  rillig lint: move all declarations above statements

All code that is used by src/tools is supposed to be compatible with C90.

No functional change.
 1.12  09-Oct-2021  rillig lint: warn if a getopt switch tries to handle unreachable ':'
 1.11  22-Aug-2021  rillig lint: fix wrong warning about '?' in getopt
 1.10  04-Jun-2021  rillig lint: fix function name in check for getopt

No functional change.
 1.9  18-Apr-2021  rillig branches: 1.9.4;
lint: pass pos_t via const pointer

Thanks for the suggestion, christos@.
 1.8  18-Apr-2021  rillig lint: migrate the getopt check to warning_at
 1.7  22-Mar-2021  rillig lint: reduce visibility of global variable for getopt check

No functional change.
 1.6  20-Feb-2021  rillig lint: reduce duplicate code in check for getopt

This also changes the conditions to their positive form, which is easier
to read.

No functional change. The resulting binary would have been the same as
before, were it not for the changed line numbers in the lint_assert
calls further down in the code.
 1.5  20-Feb-2021  rillig lint: clean up check for getopt

The original options string is not needed during the check. Having only
the unhandled options suffices.

No functional change.
 1.4  20-Feb-2021  rillig lint: fix crash from ckgetopt.c 1.2 and document the data structures
 1.3  20-Feb-2021  christos Prevent crashing when options are NULL in libc while linting
src/lib/libc/posix1e/acl_from_text.c
 1.2  19-Feb-2021  rillig lint: fix build in tools mode
 1.1  19-Feb-2021  rillig lint: warn about mismatch in getopt handling
 1.9.4.1  06-Jun-2021  cjep sync with head
 1.27.2.1  02-Aug-2025  perseant Sync with HEAD

RSS XML Feed