This program: ``` #include <boost/multi_index_container.hpp> #include <boost/multi_index/hashed_index.hpp> #include <boost/multi_index/sequenced_index.hpp> #include <boost/multi_index/key.hpp> struct HashIndex; struct SequenceIndex; using HashedThenSequenced = boost::multi_index::multi_index_container< int, boost::multi_index::indexed_by< boost::multi_index::hashed_unique< boost::multi_index::tag<HashIndex>, boost::multi_index::identity<int>>, boost::multi_index::sequenced< boost::multi_index::tag<SequenceIndex> > > >; int main() { HashedThenSequenced container; return container.empty() ? 0 : 1; } ``` ``` /tools/pkg/gcc/16.2.0/bin/g++ -std=gnu++23 -Og -Wall -Wextra -Wuninitialized -Werror=uninitialized \ -I/ws/jrichter/hf/def/toolsinclude \ -c /ws/jrichter/hf/src/base/stl/check.multiIndexUninit.cc \ -o /tmp/check.multiIndexUninit.o ``` generates this warning: ``` ...member' is used uninitialized [-Werror=uninitialized] ``` Switching the order of the indexes fixes the warning.
Activity
avoided more bogus uninitialized warnings in GCC 16 (#103)
joaquintides commentedon Sep 16, 2026
Hi Jörg, can you verify if #104 solves the problem at your end? Thank you!
J-Richter commentedon Sep 21, 2026
The warning is gone, thank you!