Boost logo

Boost :

From: Jeff Garland (jeff_at_[hidden])
Date: 2002-03-07 16:36:59

> > i don't understand you here. you want no directory_iterators?
> What you've suggested is that the library magically determined that "A:\"
> was the directory of choice (or "/bin" for Posix). I would not want that.
> On the one hand, root_directory() suggests "/" to me for Posix. On the
> other, there is no "root directory" concept on DOS-style filesystems apart
> from that of the current drive. Therefore, the behavior you described

Maybe it would help if we thought about it like this:
  --what are the available 'root directories' on the system
    on Unix this there is always one: "/"
    on Dos there are several possibly: "A:\ C:\ D:\" etc

Then from a functional point of view we need to be able to retrieve this list of
directory entry names regardless of platform. I haven't followed this whole
discussion lately, but I see no reason why this can't be a directory iterator
since the results would all be directory names. It's just that with unix we
will only iterate once since there is only one root....

> suggests that root_directory() either relied on the current directory to
> determine the current drive, thus selecting "A:\" if the current directory

Even with Beman's desire to avoid global data, we still need a function that can
return the current working directory of the process. From the working directory
name it should be possible to obtain the current root directory name. So I
don't think we want root_directory() to return the 'current' root. I haven't
looked at the latest proposal to see if what I suggested is really covered,


Boost list run by bdawes at, gregod at, cpdaniel at, john at