https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61596
Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Last reconfirmed|2014-06-26 00:00:00 |2022-1-24 --- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> --- This now warns about libstdc++ code, see PR 104019: /build/trunk/x86_64-unknown-dragonfly6.3/libstdc++-v3/include/bits/shared_ptr_base.h: In member function 'void std::_Sp_counted_array_base<_Alloc>::_M_init(typename std::allocator_traits<_Alloc>::value_type*, _Init)': /build/trunk/x86_64-unknown-dragonfly6.3/libstdc++-v3/include/bits/shared_ptr_base.h:767: warning: typedef 'using value_type = using _Up = typename std::allocator_traits<_Alloc>::value_type' locally defined but not used [-Wunused-local-typedefs] /build/trunk/x86_64-unknown-dragonfly6.3/libstdc++-v3/include/bits/shared_ptr_base.h:768: warning: typedef 'using difference_type = std::ptrdiff_t' locally defined but not used [-Wunused-local-typedefs] /build/trunk/x86_64-unknown-dragonfly6.3/libstdc++-v3/include/bits/shared_ptr_base.h:771: warning: typedef 'using iterator_category = struct std::forward_iterator_tag' locally defined but not used [-Wunused-local-typedefs] In file included from /build/trunk/x86_64-unknown-dragonfly6.3/libstdc++-v3/include/x86_64-unknown-dragonfly6.3/bits/stdc++.h:144: Those typedefs are 100% necessary because otherwise the local class is not a valid iterator type.