From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16135 invoked by alias); 20 Sep 2009 18:32:40 -0000 Received: (qmail 16113 invoked by uid 48); 20 Sep 2009 18:32:29 -0000 Date: Sun, 20 Sep 2009 18:32:00 -0000 Subject: [Bug c++/41421] New: [C++0x] Trivial types should require trivial default constructor. X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "cadaker at gmail dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2009-09/txt/msg01910.txt.bz2 The C++0x standard draft defines a trivial type as one that has trivial default construct, copy constructor, copy assignment operator and destructor. g++ from the current trunk, however, classifies types without default constructor as trivial, meaning that the following code does not compile: #include struct Foo { Foo(int) {} }; static_assert(!std::is_trivial::value, "Not trivial - no (trivial) default constructor."); This seems like a bug (unless I've misunderstood the draft or missed some pending change to it). -- Summary: [C++0x] Trivial types should require trivial default constructor. Product: gcc Version: 4.5.0 Status: UNCONFIRMED Severity: minor Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: cadaker at gmail dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41421