From: Thorsten Ottosen (nesotto_at_[hidden])
Date: 2003-03-01 17:03:24
"Kevin Atkinson" <kevin_at_[hidden]> wrote in message
> On Sat, 1 Mar 2003, Thorsten Ottosen wrote:
> > First I want to say that I'm not experienced with multitherading, but I
> > would like to see a standard lib
> > to solve these situations.
> > A small question about enforcing correct parameter passing: you have
> > typedefs :
> > // These locks should never be passed by value to functions.
> > // Instead use the following typedef to pass by reference:
> > typedef const LockOnly & WillOnlyLock;
> > typedef const Lock & WillLock;
> > typedef const UnlockOnly & WillOnlyUnlock;
> > typedef const Unlock & WillUnlock;
> > Is this the best way to enforce this? Why not just make lock objects
> > noncopyable?
> Um, they are. This typedef are strictly for convenience and readability.
what convenience and what readability? C++ programmers are use to const XX&
Having four extra names makes the concept harder to understand.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk