I'm seeing the following with MSVC 2022:
C:\git\llvm-project\clang\unittests\StaticAnalyzer\RangeSetTest.cpp(97): warning C4309: 'initializing': truncation of constant value C:\git\llvm-project\clang\unittests\StaticAnalyzer\RangeSetTest.cpp(948): note: see reference to class template instantiation '`anonymous-namespace'::TestValues<F>' being compiled C:\git\llvm-project\clang\unittests\StaticAnalyzer\RangeSetTest.cpp(942): note: while compiling class template member function 'void `anonymous-namespace'::RangeSetCastToPromotionConversionTest_Test_Test<T>::TestBody(void)'
The issue here is that RangeSetCastToPromotionConversionTest tries to instantiate the template at L947, using TV = TestValues<F>; which ends up trying to assign at L94, static constexpr T ToA = FromA + 2; which overflows with T=char. Ideally, we wouldn't need FromA/ToA/FromB/ToB for this test.