Boost logo

Boost :

From: Thomas Witt (witt_at_[hidden])
Date: 2005-05-03 19:46:05


Beman,

Beman Dawes wrote:
> "Thomas Witt" <witt_at_[hidden]> wrote in message
> news:d58cm5$mso$1_at_sea.gmane.org...
>
>>Hmm, what's the benefit of having symlink_status() and status() ? Wouldn't
>>one function suffice that sets the symlink flag when a symlink is
>>encoutered on the way. I.e.
>>
>
> I considered that briefly, but rejected it because status() on POSIX would
> then require two calls; one to stat() and one to lstat().

Hmmm .. mildly convincing.

>
> There is also a nice simplicity in the current design; the functions always
> returns a value with one and only one flag set.

In this case the fact that it is a bitmask type seems to be kind of
misleading. Isn't the whole point of a bitmask type to be able to have
multiple flags set at once?

>
> Neither of those are really killer arguments, so if others think it would be
> better to have a single status() function, I'd like to hear their arguments.

I am up in the air about it. On the one hand it seems wrong to me to
have a suboptimal interface only because posix has one, on the other
hand performance might be an issue.

Thomas

-- 
Thomas Witt
witt_at_[hidden]

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk