]> git.ipfire.org Git - thirdparty/gcc.git/commit
libstdc++: Fix bug in default ctor of extents.
authorLuc Grosheintz <luc.grosheintz@gmail.com>
Sat, 24 May 2025 11:26:55 +0000 (13:26 +0200)
committerTomasz Kamiński <tkaminsk@redhat.com>
Tue, 27 May 2025 09:12:25 +0000 (11:12 +0200)
commite46c5b3219436d92b867457c0a4465db29c42cde
treed076fc84e073b2ad1d105c313b03fffc2a5ec888
parent672569cee76a1927d14b5eb754a5ff0b9cee1bc8
libstdc++: Fix bug in default ctor of extents.

The array that stores the dynamic extents used to be default
initialized. The standard requires value intialization. This
commit fixes the bug and adds a test.

libstdc++-v3/ChangeLog:

* include/std/mdspan: Value initialize the array storing the
dynamic extents.
* testsuite/23_containers/mdspan/extents/ctor_default.cc: New
test.

Signed-off-by: Luc Grosheintz <luc.grosheintz@gmail.com>
libstdc++-v3/include/std/mdspan
libstdc++-v3/testsuite/23_containers/mdspan/extents/ctor_default.cc [new file with mode: 0644]