Module Name: src Committed By: rillig Date: Sat Feb 26 20:36:11 UTC 2022
Modified Files: src/tests/usr.bin/xlint/lint1: d_gcc_compound_statements2.c t_integration.sh src/usr.bin/xlint/lint1: cgram.y externs1.h tree.c Log Message: lint: fix memory corruption in statement expressions (since 2021-12-17) The commit that introduced the assertion failure looks innocent, it only adds a few predefined functions for GCC mode. Nevertheless, before that commit, lint consistently complained about 'error: void type illegal in expression [109]', which doesn't make sense either. This fix also removes the creative use of the initialization stack to store the type of the statement expression. Having a separate stack for these statement expressions makes the code easier to understand. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 \ src/tests/usr.bin/xlint/lint1/d_gcc_compound_statements2.c cvs rdiff -u -r1.74 -r1.75 src/tests/usr.bin/xlint/lint1/t_integration.sh cvs rdiff -u -r1.380 -r1.381 src/usr.bin/xlint/lint1/cgram.y cvs rdiff -u -r1.145 -r1.146 src/usr.bin/xlint/lint1/externs1.h cvs rdiff -u -r1.403 -r1.404 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.