https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125541

--- Comment #2 from programmer00001h at gmail dot com ---
I actually wondered about reflection while reading the Itanium ABI recently,
but apparently GCC can mangle the anonymous union in function parameters just
fine:

#include<type_traits>
#include<meta>
struct T{union{};};

using anonymous =
[:members_of(^^T,std::meta::access_context::unchecked())[0]:];

static_assert(std::is_union_v<anonymous>);

void foo(anonymous){}

https://godbolt.org/z/6n3EnePj6

so I'm not sure what's going on here.

Reply via email to