Skip to content

Latest commit

 

History

History
51 lines (32 loc) · 1.24 KB

is-trivially-default-constructible-class.md

File metadata and controls

51 lines (32 loc) · 1.24 KB
description title ms.date f1_keywords helpviewer_keywords ms.assetid
Learn more about: is_trivially_default_constructible Class
is_trivially_default_constructible Class
11/04/2016
type_traits/std::is_trivially_default_constructible
is_trivially_default_constructible
653ecd73-909f-4dd8-b95a-d1164d1c2da4

is_trivially_default_constructible Class

Tests if type has trivial default constructor.

Syntax

template <class Ty>
struct is_trivially_default_constructible;

Parameters

Ty
The type to query.

Remarks

An instance of the type predicate holds true if the type Ty is a class that has a trivial constructor, otherwise it holds false.

A default constructor for a class Ty is trivial if:

  • it is an implicitly declared default constructor

  • the class Ty has no virtual functions

  • the class Ty has no virtual bases

  • all the direct bases of the class Ty have trivial constructors

  • the classes of all the non-static data members of class type have trivial constructors

  • the classes of all the non-static data members of type array of class have trivial constructors

Requirements

Header: <type_traits>

Namespace: std

See also

<type_traits>