Boost logo

Boost Users :

From: me22 (me22.ca_at_[hidden])
Date: 2006-01-01 13:21:00


On 01/01/06, Phil Endecott <spam_from_boost_users_at_[hidden]> wrote:
> I disagree with the first comment: "The only logical form of copy would
> be to use some sort of shallow copy semantics in which multiple mutex
> objects could refer to the same mutex state." What's wrong with the
> copy of a mutex being a new independent mutex? (There's a problem if
> you copy a locked mutex, but I don't propose to do that.)
>

I think that would be more confusing, personally, since it wouldn't be
making a copy. With non-copyable you get a compiler error if you try
to copy it; with a do-nothing copy things would compile but not copy
any sort of state or behaviour, which a copy would intuitively be
expected to do.

- Scott


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net