Subject: bug#57102: 29.0.50; Peculiar file-name-split edge case

From: Eli Zaretskii <[email-masked]>
Date: Mon, 15 Aug 2022 14:35:28 +0300

> Cc: [email-masked]
> From: Lars Ingebrigtsen <[email-masked]>
> Date: Mon, 15 Aug 2022 07:54:34 +0200
> 
> That is, perhaps what we want is
> 
> (file-name-split "a/b")
> => '("a" "b")
> 
> (file-name-split "a/b/")
> => '("a" "b")
> 
> (file-name-split "/a/b")
> => '("a" "b")

This should return '("/" "a" "b"), or '("/a" "b")  I think.

> (file-name-split "//a////b////")
> => '("a" "b")

And this should return '("/" "a" "b" "/"), or '("/a" "b/").

> I'm not sure what
> 
> (file-name-split "c:/a/b")
> 
> on Windows should return in that case, though.

If you agree with the above, then '("c:/" "a" "b").

If you don't care about the root directory, then '("a" "b")
(a.k.a. "leave the interpretation to the caller").