From: Glen Knowles (gknowles_at_[hidden])
Date: 2004-07-21 19:21:41
> From: Howard Hinnant [mailto:hinnant_at_[hidden]]
> > I mostly agree with Bronek Kozicki. Given a movable lock, Eric
> > Niebler's
> > proposal:
> > scoped_lock try_lock( Mutex & m );
> > scoped_lock timed_lock( Mutex & m );
> > is a better try/timed interface. Heisenberg constructors must die.
> Sorry, I don't know what a Heisenberg constructor is.
It's a reference to the Heisenberg uncertainty principle. Constructors that
sometimes act one way and sometimes another must die. ;)
> From: David Abrahams [mailto:dave_at_[hidden]]
> Howard Hinnant <hinnant_at_[hidden]> writes:
> > scoped_lock lk1(m, defer_lock); // not locked
> ^^^^ ^^^^
> Redundant. "deferred" is better.
If you named it not_locked you wouldn't need the comment. ;)
Of these three choices:
1. try, deferred
2. try_lock, deferred
3. try_lock, defer_lock
I tend to like #3 the best.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk