Modify

Opened 8 years ago

Closed 7 years ago

#3244 closed Patches (fixed)

XLC warnings about missing "private" keyword when extending boost::noncopyable

Reported by: Ioannis Papadopoulos <ipapadop@…> Owned by: anthonyw
Milestone: Boost 1.40.0 Component: thread
Version: Boost 1.39.0 Severity: Problem
Keywords: mutex private noncopyable xlc warning Cc:

Description

xlc 10.1 throws warnings whenever boost::mutex and boost::recursive_mutex are used because of missing access specifier.

Example output:

"/usr/local/include/boost/thread/pthread/mutex.hpp", line 30.9: 1540-0198 (W) The omitted keyword "private" is assumed for base class "boost::noncopyable".

Attachments (2)

3244.patch (3.7 KB) - added by viboes 7 years ago.
3244_2.patch (3.8 KB) - added by viboes 7 years ago.
Correct issue with thread_group default constructor on 4344.patch

Download all attachments as: .zip

Change History (7)

comment:1 in reply to: ↑ description Changed 8 years ago by viboes

Replying to Ioannis Papadopoulos <ipapadop@…>:

xlc 10.1 throws warnings whenever boost::mutex and boost::recursive_mutex are used because of missing access specifier.

Example output:

"/usr/local/include/boost/thread/pthread/mutex.hpp", line 30.9: 1540-0198 (W) The omitted keyword "private" is assumed for base class "boost::noncopyable".

Could you show an example?

comment:2 follow-up: Changed 7 years ago by viboes

Following the update to follow more closely C++0X delete operation, instead of inheriting from boost::noncopyable, we can replace by the explicit private constructors

private:

mutex(mutex const&); mutex& operator=(mutex const&);

See attachments.

Changed 7 years ago by viboes

Changed 7 years ago by viboes

Correct issue with thread_group default constructor on 4344.patch

comment:3 in reply to: ↑ 2 Changed 7 years ago by viboes

Replying to viboes:

See attachments.

Take 3244_2.patch, 3244.patch has a bug on thread_group default constructor.

comment:4 Changed 7 years ago by viboes

  • Type changed from Bugs to Patches

comment:5 Changed 7 years ago by anthonyw

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

Fixed on trunk.

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain anthonyw.
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.