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

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
According to https://gcc.gnu.org/onlinedocs/gcc/Type-Traits.html the
precondition for __is_trivial is:

"Requires: type shall be a complete type, (possibly cv-qualified) void, or an
array of unknown bound."

That implies the following should be valid:

struct Inc;
bool b = __is_trivial(Inc[]);

However, the implementation seems to match the requirement for the
std::is_trivial trait, which is:
"remove_all_extents_t<T> shall be a complete type or cv void."

This seems to be just a documentation bug.

Reply via email to