]> git.ipfire.org Git - thirdparty/gcc.git/commit
Use Object Size Type zero for -Warray-bounds [PR101374].
authorMartin Sebor <msebor@redhat.com>
Thu, 8 Jul 2021 17:34:27 +0000 (11:34 -0600)
committerMartin Sebor <msebor@redhat.com>
Thu, 8 Jul 2021 17:43:47 +0000 (11:43 -0600)
commit9bf9f27ac6db4823628c435da9b242fd82bf8d68
treeeb069a0bbba285e95cf3db4c4c11742f6fc26117
parent1ca642d785c49e9e0b28651b190720267703f023
Use Object Size Type zero for -Warray-bounds [PR101374].

Resolves:
PR bootstrap/101374 - -Warray-bounds accessing a member subobject as derived

gcc/cp/ChangeLog:
PR bootstrap/101374
* module.cc (module_state::read_macro_maps): Temporarily disable
-Warray-bounds.
(module_state::install_macros): Same.

gcc/ChangeLog:
PR bootstrap/101374
* gimple-array-bounds.cc (array_bounds_checker::check_mem_ref):
Use Object Size Type 0 instead of 1.

gcc/testsuite/ChangeLog:
PR bootstrap/101374
* c-c++-common/Warray-bounds-3.c: Xfail assertion.
* c-c++-common/Warray-bounds-4.c: Same.
gcc/cp/module.cc
gcc/gimple-array-bounds.cc
gcc/testsuite/c-c++-common/Warray-bounds-3.c
gcc/testsuite/c-c++-common/Warray-bounds-4.c