[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix.
From: |
Michael Albinus |
Subject: |
Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix. |
Date: |
Sat, 24 Jul 2021 21:04:00 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Lars Ingebrigtsen <larsi@gnus.org> writes:
>> FTR, I believe COMPONENTS might also contain nil elements, which should
>> be ignored.
>
> I'm not sure I follow. You want to extend the interface to allow nil
> elements? I'm not sure that would be very useful?
It's rather a nice to have. Sometimes, I have a list of file name
fragments, and I hope to avoid the checks for being non-empty strings
...
But I can do this in my code.
>> Furthermore, we have
>>
>> (directory-append "foo/" "/bar") => "foo//bar"
>>
>> I would expect "foo/bar", meaning that all leading slashes in COMPONENTS
>> are removed.
>
> Well, I think that's over into DWIM-land again (which is what
> expand-file-name does, and this function deliberately doesn't do).
expand-file-name and file-name-as-directory are functions which call a
handler, for example Tramp. directory-append is much cheaper, and if it
could do this string handling, I could avoid those functions. It would
be more performant.
Best regards, Michael.
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Michael Albinus, 2021/07/24
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Lars Ingebrigtsen, 2021/07/24
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix.,
Michael Albinus <=
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Lars Ingebrigtsen, 2021/07/25
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Stefan Monnier, 2021/07/25
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Lars Ingebrigtsen, 2021/07/25
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Kévin Le Gouguec, 2021/07/25
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Lars Ingebrigtsen, 2021/07/25
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Andreas Schwab, 2021/07/25
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Kévin Le Gouguec, 2021/07/25
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Lars Ingebrigtsen, 2021/07/28
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Michael Albinus, 2021/07/28
- Re: master e315544: ; * src/fileio.c (Fdirectory_append): Doc fix., Lars Ingebrigtsen, 2021/07/30