Greetings, and thanks for your feedback!

I guess the simple answer is that lisp is not unix.  While archaic and
arguably obsolete at present, the language went to some considerable
effort to abstract away file system semantics.  If you want to take a
look at how far this went, check out logical-pathnames.

pathname-directory can basically be a string, nil, :unspecific, or a
list of strings, though elsewhere it makes clear :relative, :absolute,
:wild, and :wild-inferiors are acceptable members of the list.  The idea
being if the list element was a string, it directly corresponded to a
directory element in the surrounding operating system. "foo/////bar"
would logically imply empty strings breaking this, but in GCL's current
support we just swallow '//' in the parser.

Realistically, such paths are *never* intentional it would seem and are
just accidental artifacts of by hand pathname merging.  So it does seem
we are just covering up code which could be better written using
merge-pathnames out of convenience, but as real users appear to want
this at least at the moment, I am not going to be pedantic about it.

Take care,

Andrey Grozin wrote:

> On Sat, 21 Feb 2026, Camm Maguire wrote:
> 
>     Greetings!  Seems fine in my tests, but I'm still unsure whether it is
>     not better to throw an error and point out the faulty pathname
>     concatenation.  Seems like we are just covering up bad code out of
>     convenience.
>     
> In any Unix-like system,
> foo//////////bar
> is absolutely legal, and identical to
> foo/bar
> Why throw an error for an absolutely correct pathname?
> 
> Andrey

-- 
Camm Maguire                                        [email protected]
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah

Reply via email to