This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug sanitizer/80269] ICE with compile time constant sized array when using address sanitizer


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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |DUPLICATE

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
With -std=c++11 the assumption that this is compile time constant sized array
is bogus, std::max is constexpr only in -std=c++14 and later.  It doesn't
matter if your variable is const, it is still initialized at runtime, so char
array[LIM]
is a VLA and this ICEs because of the PR79993.

*** This bug has been marked as a duplicate of bug 79993 ***

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]