http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52702

             Bug #: 52702
           Summary: [C++11] std::is_trivially_destructible is missing
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
        AssignedTo: unassig...@gcc.gnu.org
        ReportedBy: daniel.krueg...@googlemail.com


gcc 4.8.0 20120318 (experimental) in C++11 mode rejects the following code:

//-----
#include <type_traits>

struct pod {};
struct non_pod { ~non_pod(); };

static_assert(std::is_trivially_destructible<pod>::value, "");
static_assert(std::is_trivially_destructible<int>::value, "");
static_assert(!std::is_trivially_destructible<non_pod>::value, "");
//-----

due to the missing definition of the is_trivially_destructible type trait.

This should not be much work, because the TR1 trait has_trivial_destructor does
exist and uses the __has_trivial_destructor intrinsic and is_destructible is
also provided.

Reply via email to