https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128330
--- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Dominic Plunkett <[email protected]>: https://gcc.gnu.org/g:8bc1f8969d4a9c59455dd10d05267e6e0179d6ef commit r17-6985-g8bc1f8969d4a9c59455dd10d05267e6e0179d6ef Author: Dominic P <[email protected]> Date: Tue Dec 1 11:05:35 2026 +0000 cfgexpand: Require an INTEGER_TYPE for character arrays [PR128330] As Richard requested, test for INTEGER_TYPE rather than INTEGRAL_TYPE_P when deciding whether an array is a character array. This still covers char_type_node after LTO streaming and the array CCP creates for a VLA of constant size, but arrays of std::byte, of enums with a char underlying type, of _BitInt(8) and of Ada's Boolean are again not character arrays, as they were not before r17-6827. Assisted-by: Claude Opus 5.5 (Anthropic) Signed-off-by: Dominic P <[email protected]> PR lto/128330 gcc/ChangeLog: * cfgexpand.cc (stack_protect_classify_type): Require an INTEGER_TYPE of char precision for a character array. gcc/testsuite/ChangeLog: * g++.dg/fstack-protector-char8.C: Expect std::byte arrays to be unprotected. * gcc.dg/fstack-protector-bitint.c: Expect _BitInt(8) arrays to be unprotected.
