Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src



Module Name:    src
Committed By:   rillig
Date:           Sat Aug 14 12:46:24 UTC 2021

Modified Files:
        src/tests/usr.bin/xlint/lint1: d_c99_bool_strict.exp
            d_c99_bool_strict_syshdr.exp d_init_array_using_string.exp
            msg_115.c msg_115.exp msg_124.exp msg_164.c msg_164.exp msg_242.c
            msg_242.exp
        src/usr.bin/xlint/lint1: init.c ops.def tree.c

Log Message:
lint: allow initialization of struct with constant member

The operator INIT, just like RETURN and FARG, initializes an object with
an expression.  The target object of such an initialization may be a
struct with constant members.

The operator ASSIGN, on the other hand, is entirely different.  It
overwrites the existing value of the object, and this is not allowed for
structs that have a constant member.  Therefore it was wrong to use the
operator ASSIGN for initialization.


To generate a diff of this commit:
cvs rdiff -u -r1.27 -r1.28 \
    src/tests/usr.bin/xlint/lint1/d_c99_bool_strict.exp
cvs rdiff -u -r1.10 -r1.11 \
    src/tests/usr.bin/xlint/lint1/d_c99_bool_strict_syshdr.exp
cvs rdiff -u -r1.4 -r1.5 \
    src/tests/usr.bin/xlint/lint1/d_init_array_using_string.exp
cvs rdiff -u -r1.7 -r1.8 src/tests/usr.bin/xlint/lint1/msg_115.c
cvs rdiff -u -r1.6 -r1.7 src/tests/usr.bin/xlint/lint1/msg_115.exp
cvs rdiff -u -r1.9 -r1.10 src/tests/usr.bin/xlint/lint1/msg_124.exp
cvs rdiff -u -r1.3 -r1.4 src/tests/usr.bin/xlint/lint1/msg_164.c \
    src/tests/usr.bin/xlint/lint1/msg_242.c
cvs rdiff -u -r1.2 -r1.3 src/tests/usr.bin/xlint/lint1/msg_164.exp \
    src/tests/usr.bin/xlint/lint1/msg_242.exp
cvs rdiff -u -r1.207 -r1.208 src/usr.bin/xlint/lint1/init.c
cvs rdiff -u -r1.23 -r1.24 src/usr.bin/xlint/lint1/ops.def
cvs rdiff -u -r1.332 -r1.333 src/usr.bin/xlint/lint1/tree.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index