From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28121 invoked by alias); 14 Oct 2013 21:01:52 -0000 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 Received: (qmail 28097 invoked by uid 48); 14 Oct 2013 21:01:49 -0000 From: "kwbent at uab dot edu" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/58729] New: tr2::dynamic_bitset::resize fails Date: Mon, 14 Oct 2013 21:01:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 4.8.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: minor X-Bugzilla-Who: kwbent at uab dot edu X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-10/txt/msg00833.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58729 Bug ID: 58729 Summary: tr2::dynamic_bitset::resize fails Product: gcc Version: 4.8.1 Status: UNCONFIRMED Severity: minor Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: kwbent at uab dot edu Created attachment 31004 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=31004&action=edit output from compilation using g++ (Debian 4.8.1-10) 4.8.1 Debian testing x64 I've been investigating the dynamic_bitset part of the tr2 specification. I've used boost's dynamic bitset, so I was basing the functionality from that. Either I'm using the resize function wrongly, or it's failing to set the bits as indicated. When using the resize(number of bits, value), the resize seems to work fine, but the value is ignored. I started to dig around; the resize function is defined as this in the header void resize(size_type __nbits, bool __value = false) { this->_M_resize(__nbits, __value); this->_M_Nb = __nbits; this->_M_do_sanitize(); } Is the value being defaulted to false, regardless of the input? The actual main() is at the end of the main.ii file. Another oddity is that this will not compile from the command line, but will from inside netbeans where I code, even with Wall and Wextra specified. If more info is needed, I'll oblige.