https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98539

--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Martin Uecker <[email protected]>:

https://gcc.gnu.org/g:dcd83c656ef1c00d5b5a70deb7ba608e68a8aea4

commit r17-1146-gdcd83c656ef1c00d5b5a70deb7ba608e68a8aea4
Author: Martin Uecker <[email protected]>
Date:   Sat May 30 16:30:50 2026 +0200

    c: fix false positive for -Wvla-parameter [PR98539]

    In case of VLAs that are multi-dimensional arrays with unspecified sizes,
    the test in the warning code did not work correctly.  Fix this by
    explicitely checking that there are specified or unspecified size
    expressions to determine the presence of a VLA.

            PR c/98539

    gcc/c-family/ChangeLog:
            * c-warn.cc (warn_parm_array_mismatch): Check number of size
            expressions.

    gcc/testsuite/ChangeLog:
            * gcc.dg/pr98539.c: New test.

Reply via email to