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

Nick Sabalausky a at a.a
Wed Mar 2 13:39:36 PST 2011


"Kagamin" <spam at here.lot> wrote in message 
news:iklanl$1qg$1 at digitalmars.com...
> Nick Sabalausky Wrote:
>
>> Name one case in windows where some sort of distinction between filename 
>> and
>> extension actually makes a real tangible difference versus unix, that
>> doesn't merely amount to convention
>
> You can pass program path to CreateProcess without extension, .exe is 
> assumed.

I really don't think that indicates that Windows doesn't consider extension 
part of the filename. It just expects the filename to have an extension for 
certain file types. It's basically just a shortcut for:

if(tryingToRunAProgram && !hasExt(filename))
    filenameRegex = filename~"\.(exe|com|bat)";




More information about the Digitalmars-d mailing list