https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80601
--- Comment #2 from Jens Maurer <jens.maurer at gmx dot net> --- (In reply to Jonathan Wakely from comment #1) > Strictly speaking the compiler is correct that the type of sizeof(T) is not > dependent, so for LP64 targets will always need a conversion to a narrower > type. Right, but I would expect -Wconversion warnings to respect the C++ narrowing rules for brace-initialization, which (among other things) state for integer conversions that there is no narrowing if the original constant value fits into the target type. In the following example, there is no error or warning; the narrowing check is (correctly) postponed to template instantiation time: template<class T> void g(T) { unsigned int x { sizeof(T) }; }