Bug 491537 - dynamic_bitset/dynamic_bitset.hpp won't compile
Summary: dynamic_bitset/dynamic_bitset.hpp won't compile
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: boost
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Benjamin Kosnik
QA Contact: Fedora Extras Quality Assurance
URL: https://svn.boost.org/trac/boost/tick...
Whiteboard:
Depends On:
Blocks: 476346
TreeView+ depends on / blocked
 
Reported: 2009-03-22 19:47 UTC by Mamoru TASAKA
Modified: 2013-08-09 05:48 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2009-03-23 15:09:04 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Patch to workaround for this issue (700 bytes, patch)
2009-03-22 19:47 UTC, Mamoru TASAKA
no flags Details | Diff

Description Mamoru TASAKA 2009-03-22 19:47:45 UTC
Created attachment 336217 [details]
Patch to workaround for this issue

Description of problem:

The following "boost.cpp":
-------------------------------------------------------------
#include <boost/dynamic_bitset.hpp>
-------------------------------------------------------------
won't compile like:

$ g++ -c -o boost.o boost.cpp
In file included from /usr/include/boost/dynamic_bitset.hpp:15,
                 from boost.cpp:1:
/usr/include/boost/dynamic_bitset/dynamic_bitset.hpp: In member function ‘size_t boost::dynamic_bitset<Block, Allocator>::count() const’:
/usr/include/boost/dynamic_bitset/dynamic_bitset.hpp:1021: error: ‘mode’ cannot appear in a constant-expression
/usr/include/boost/dynamic_bitset/dynamic_bitset.hpp:1021: error: template argument 1 is invalid
/usr/include/boost/dynamic_bitset/dynamic_bitset.hpp:1021: error: expected ‘>’ before ‘*’ token
/usr/include/boost/dynamic_bitset/dynamic_bitset.hpp:1021: error: expected ‘(’ before ‘*’ token
/usr/include/boost/dynamic_bitset/dynamic_bitset.hpp:1021: error: expected primary-expression before ‘>’ token


Version-Release number of selected component (if applicable):
boost-1.37.0-4.fc11.i586
gcc-4.4.0-0.28.i586

How reproducible:
100%

Steps to Reproduce:
1. See above
2.
3.

Expected results:
Should compile

Additional info:
Workaround patch attached, although I don't know exactly
why this is needed...

Comment 1 Petr Machata 2009-03-23 13:47:00 UTC
Weird.  It's all const values, I think gcc should be able to instantiate it.
Anyway, I applied the patch, and the build is currently spinning (I'm thinking that bugfixes like this don't break the freeze policy).

Comment 2 Thomas Moschny 2009-03-24 17:51:50 UTC
Shouldn't that issue be presented to the gcc packagers/devs then?


Note You need to log in before you can comment on or make changes to this bug.