The g++.dg/reflect/type_trait14.C test FAILs with -fimplicit-constexpr,
because in that case NLType is actually a literal type rather than
non-literal type and so is structural type too.
Fixed by making sure it is not a literal type even with
-fimplicit-constexpr.
2026-04-10 Jakub Jelinek <jakub@redhat.com>
PR c++/124844
* g++.dg/reflect/type_trait14.C (NLType::~NLType): Move definition out
of the class.
Reviewed-by: Jason Merrill <jason@redhat.com>
NLType () : _M_i(0) { }
constexpr NLType (int __i) : _M_i(__i) { }
NLType (const NLType &__other) : _M_i(__other._M_i) { }
- ~NLType () { _M_i = 0; }
+ ~NLType ();
};
+NLType::~NLType () { _M_i = 0; }
static_assert (is_structural_type (^^int));
static_assert (is_structural_type (^^float));