Modify

Opened 9 years ago

Closed 9 years ago

#1852 closed Bugs (wontfix)

copy constructor does not copy capacity

Reported by: srajko Owned by: jano_gaspar
Milestone: To Be Determined Component: circular_buffer
Version: Boost Development Trunk Severity: Problem
Keywords: Cc:

Description

After looking at the code, the following behavior looks like a bug:

boost::circular_buffer<int> one(3); boost::circular_buffer<int> two(one);

std::cout<<one.capacity()<<std::endl; outputs 3 std::cout<<two.capacity()<<std::endl; outputs 0, I was expecting 3

My best guess at a patch attached.

Attachments (1)

base.hpp.patch (992 bytes) - added by srajko 9 years ago.
patch

Download all attachments as: .zip

Change History (5)

Changed 9 years ago by srajko

patch

comment:1 Changed 9 years ago by srajko

  • Summary changed from copy constructor not copy capacity to copy constructor does not copy capacity

comment:2 Changed 9 years ago by jano_gaspar

  • Resolution set to fixed
  • Status changed from new to closed

comment:3 Changed 9 years ago by dthompson@…

  • Resolution fixed deleted
  • Status changed from closed to reopened

this problem is still encountered in boost 1.35.

comment:4 Changed 9 years ago by jano_gaspar

  • Resolution set to wontfix
  • Status changed from reopened to closed

will not fix for 1.35

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain jano_gaspar.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.