std.path.getName(): Screwy by design?

Nick Sabalausky a at a.a
Tue Mar 1 01:31:52 PST 2011


"Jonathan M Davis" <jmdavisProg at gmx.com> wrote in message 
news:mailman.2076.1298971012.4748.digitalmars-d at puremagic.com...
>
> I think that I agree with you on all counts. I can understand if the path 
> stuff
> can't deal with / or \ in file names (that's probably not worth trying to 
> get to
> work right), but it _should_ be able to handle directories with dots in 
> them and
> files with no extension. Files without extension may be uncommon in 
> Windows, but
> they're common enough on Linux.
>

Due to the practical need for dealing with Unixy systems (for instance, an 
external web server) and cross-OS compatibility, etc, I deal with 
extension-less files (and filenames that start with a dot) quite frequently 
even on Windows, and even though I'm primarily a Windows user.

That reminds me of something I've often wondered, though: Does unix consider 
a file named ".bashrc" to be a nameless file with an extension of "bashrc", 
or just an extentionless file named ".bashrc"? (I know unix doesn't 
typically have a concept of file extension, it's all just part of the name, 
but unix programs will often care about the extension portion of a 
filename.)




More information about the Digitalmars-d mailing list