https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114395
Bug ID: 114395 Summary: std::is_constructible_v result of const reference incorrect Product: gcc Version: 14.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: yronglin777 at gmail dot com Target Milestone: --- https://godbolt.org/z/h5af6f5x9 ``` #include <type_traits> struct A { int a; }; struct B : public A {}; static_assert(!std::is_constructible_v<const B &, const A &>); static_assert(!std::is_constructible_v<const B *, const A *>); ``` Clang and MSVC accepted this code, but gcc rejected. ``` <source>:8:15: error: static assertion failed 8 | static_assert(!std::is_constructible_v<const B &, const A &>); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Compiler returned: 1 ```