This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/43230] [4.5 regression] Revision 157158 failed 30_threads/promise/members/set_value3.cc
- From: "redi at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 2 Mar 2010 14:13:45 -0000
- Subject: [Bug c++/43230] [4.5 regression] Revision 157158 failed 30_threads/promise/members/set_value3.cc
- References: <bug-43230-682@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from redi at gcc dot gnu dot org 2010-03-02 14:13 -------
The fix is to remove the ~tester destructor, it's invalid to test the future's
state from the tester destructor, because the future state has already started
being destroyed and its condition_variable and mutex get destroyed before the
tester object.
An alternative would be to re-order the members of _State so the condvar and
mutex are destroyed later, but the test is still relying on behaviour that
isn't guaranteed, so I'll change the test.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43230