Opened 11 years ago

Closed 10 years ago

#5608 closed Bugs (fixed)

Cannot compile using <boost/thread.hpp> on QNX 6.5.0: error: overriding 'virtual boost::exception::~exception() throw ()'

Reported by: Bryan Godbolt <godbolt@…> Owned by: Emil Dotchevski
Milestone: To Be Determined Component: exception
Version: Boost 1.46.1 Severity: Problem
Keywords: Cc: viboes

Description

I'm using qnx 6.5.0 with qcc: # qcc -V cc: targets available in /usr/qnx650/host/qnx6/x86/etc/qcc:

4.4.2,gcc_ntox86_acpp-ne 4.4.2,gcc_ntox86_gpp 4.4.2,gcc_ntox86_ecpp 4.4.2,gcc_ntox86_acpp 4.4.2,gcc_ntox86_ecpp-ne 4.4.2,gcc_ntox86 (default) 4.4.2,gcc_ntox86_cpp 4.4.2,gcc_ntox86_cpp-ne

when I try to compile a file where I included <boost/thread.hpp> I get the following error: /opt/qnx650/target/qnx6/usr/local/include/boost/exception/detail/exception_ptr.hpp:69: error: looser throw specifier for 'virtual boost::exception_detail::bad_alloc_::~bad_alloc_()' /opt/qnx650/target/qnx6/usr/local/include/boost/exception/exception.hpp:255: error: overriding 'virtual boost::exception::~exception() throw ()'

By explicitly specifying a throw list for the destructor of bad_alloc_ the problem can be solve. e.g., in exception_ptr.hpp

struct bad_alloc_ :

boost::exception, std::bad_alloc

{

~bad_alloc_() throw() {}

};

Change History (2)

comment:1 by viboes, 11 years ago

Cc: viboes added
Component: threadexception
Owner: changed from Anthony Williams to Emil Dotchevski

I don't see any wrong here for Boost.Thread and the suggested modification is already in Trunk.

I will prefer the Boost.Exception maintainers close it if they think the issue is solved.

comment:2 by Emil Dotchevski, 10 years ago

Resolution: fixed
Status: newclosed

Not sure when this was fixed but it is fixed.

Note: See TracTickets for help on using tickets.