Why does std::is_trivial work different in different compilers?

117 views Asked by At

Why does

class C {
private:
    C() = default;
};

static_assert(std::is_trivial_v<C>)

compile fine with gcc but not with msvc?

error C2607: static assertion failed

As show https://godbolt.org/z/e4Yo9KWo9

0

There are 0 answers