Next in Review Queue: The New std.path

Lars T. Kyllingstad public at kyllingen.NOSPAMnet
Fri Jul 15 08:43:58 PDT 2011


On Fri, 15 Jul 2011 16:08:37 +0800, KennyTM~ wrote:

> IANAL, but there should be mention of the Boost license somewhere.

Oops, seems I forgot.


> ssize_t (Line 50):     Why not use sizediff_t?

Mainly because I wasn't aware of its existence. ;)  I'll fix.

(I still think ssize_t is a better name, though, and now that you mention 
it, I recall Andrei and Walter discussing this on the Phobos mailing list 
a few months ago.)


> Line 58..67: I think
> version blocks should be like
> 
>      version (Windows)
>      {
>        ...
>      }
>      else version (Posix)
>      {
>        ...
>      }
>      else
>         static assert(0, "unsupported platform");

Good point.

 
> pathSplitter: Is it possible to make it a bidirectional range (implement
> .back and .popBack())?

It is probably possible, but I don't think the increased complexity will 
be worth it.  Feel free to try to change my mind, though. ;)


> pathCharMatch: On OS X the file system is case-insensitive by default.
> Also, I'm not sure if restricting to ASCII is fine. Actually the
> case-sensitivity is independent of the platform, e.g. you can configure
> a case-sensitive disk on Windows.

Hmm.. how about I add an optional caseSensitive parameter (to both 
pathCharMatch and glob) that defaults to false on Windows and true on 
POSIX?

-Lars


More information about the Digitalmars-d mailing list