Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » U++ community news and announcements » CoWorkNX
CoWorkNX [message #50510] Mon, 12 November 2018 11:29
mirek is currently offline  mirek
Messages: 11700
Registered: November 2005
Ultimate Member
There was a little problem with CoWork:

In order to propagate exceptions from worker threads, CoWork destructor adds "noexcept(false)" specification. That works fine for stack based CoWork, but if you want to include CoWork as member variable, this propagates to parent's destructor. Now if the class is derived and has virtual destructor, this leads to compile error as noexcept specification is changed from the base.

So I have introduced a simple adapting class CoWorkNX, which just derives from CoWork and changes destructor to normal "noexcept(true)".

The moral of the story can be summarized as: If you have added CoWork as member variable and you are getting a compile time error, just change the type to CoWorkNX.
Previous Topic: C++ 17 now supported
Next Topic: Jsonize/Xmlize with lambda (and common template example)
Goto Forum:
  


Current Time: Sun Feb 17 10:56:30 CET 2019

Total time taken to generate the page: 0.00533 seconds