You are right. I had the code written as you said it should be but I
accidentally typed in the mutex name instead of the lock name.
Thanks for your help.
- Michael
--- In Boost-Users@yahoogroups.com, "William E. Kempf"
Michael said:
I am having trouble getting the boost thread library to work. I
using Borland C++Builder 6 (on Win2k), and I tried the 1.29.0 release and the 1.30.0.b1 beta release and both give me the same errors in the condition.hpp file:
line 93: " 'operator!' not implemented in type 'recursive_mutex' for arguments of the same type"
and
line 96: " 'recursive_mutex::m_mutex' is not accessible"
Looking at these lines and making some assumptions, I think you're
the wrong type to wait(). You need to pass a Lock, not a Mutex. IOW I think you have something like this:
recursive_mutex mx; condition cond; while (pred) cond.wait(mx);
when you should instead have this:
recursive_mutex mx; condition cond; recursive_mutex::scoped_lock lock(mx); while (pred) cond.wait(lock);
Plus another 5 errors. I tried to look at the condition and recursive_mutex class definitions and I do not understand how
am passing they are
implemented. Am I using it wrong to get that error?
I believe so, but you'll have to let me know if I interpreted things correctly.
-- William E. Kempf