From: Howard Hinnant (hinnant_at_[hidden])
Date: 2006-11-01 16:33:33
On Nov 1, 2006, at 2:34 PM, Roland Schwarz wrote:
> Could you please provide an example where it is not possible to
> solve the problem with scoped_lock only? I simply cannot find
> one. Currently this would be the only "killer argument" for my
> proposed aggregate/POD type mutex. Therfore I am very interested
> in this.
The implementation of condition variables on Windows is an example of
where you want to lock/unlock in a non-scoped pattern (if I'm
understanding your question correctly).
> Are users of the library "allowed" to access them directly?
> If yes why? Isn't this redundant to locks?
Yes. So clients can write their own mutexes and use them with
std::locks (and vice-versa).
> E.g. the requirement for these N2094 mutex concepts would make
> implementation of my proposed POD mutex variant impossible.
I think a statically initialized mutex is very important. I hope we
can solve this one. Might take a language extension...
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk