Subject: Re: bug#79036: [PATCH] Fix pdb tracking for remote filenames

From: Eli Zaretskii <[email-masked]>
Date: Thu, 17 Jul 2025 18:56:12 +0300

> From: Michael Albinus <[email-masked]>
> Cc: [email-masked],  [email-masked],  [email-masked]
> Date: Thu, 17 Jul 2025 17:52:59 +0200
> 
> > And I'm not sure I understand what you are trying to say here:
> >
> >> expand-file-name has a price on remote systems, it should be called
> >> explicitly by the callee of file-remote-name
> >
> > (I guess you meant "caller", not "callee".)
> 
> Of course.
> 
> > If you want to avoid the
> > price of calling expand-file-name when FILE is already expanded, we
> > can call expand-file-name only on relative file names and only if
> > default-directory is local.  Would that solve the problem?
> 
> It isn't simply needed.

How so?

> Whatever the new function returns, it is good for being used with
> expand-file-name. Just a granular function.
> 
> It is up to the callee (sic :-) to apply expand-file-name if needed.

If they will always call expand-file-name on the result, we might as
well call it internally and make the usage simpler.