On Fri, 24 Mar 2023, 17:05 Filippo Bistaffa via Gcc-help, < gcc-help@gcc.gnu.org> wrote: > I was playing around with gcc-trunk's support for C++23's std::float13_t > and I found out that, while float is constructible from double, as far as I > can tell std::float13_t is not. > In other words, the following code compiles OK: > > #include > #include > int main() { > std::vector x(5); > std::vector y(std::begin(x), std::end(x)); > } > > whereas the following does not: > > #include > #include > int main() { > std::vector x(5); > std::vector y(std::begin(x), std::end(x)); > } > > See this snippet . > Am I missing something or is it supposed to be like that? > Yes, this is the correct behaviour. The C++23 standard says: "A prvalue of floating-point type can be converted to a prvalue of another floating-point type with a greater or equal conversion rank ([conv.rank] ). A prvalue of standard floating-point type can be converted to a prvalue of another standard floating-point type."