[Bug c++/123237] [reflection] ICE: in write_type, at cp/mangle.cc:2744
mpolacek at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Mar 9 22:02:28 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123237
--- Comment #8 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Another, without requires:
```
#include <type_traits>
template <auto I>
struct X {};
struct Y {
int name;
};
template <decltype(^^::) R>
constexpr auto foo (typename [:R:] s) {
return X<^^[:R:]::name> {};
}
constexpr auto a = foo<^^Y> (Y { 42 });
static_assert (std::is_same_v <decltype (a), const X <^^Y::name>>);
```
More information about the Gcc-bugs
mailing list