GNU bug report logs -
#31357
26.1; tramp-make-tramp-file-name: incompatible lisp changes in 26.1 ?
Previous Next
Reported by: Phil Sainty <psainty <at> orcon.net.nz>
Date: Thu, 3 May 2018 14:25:02 UTC
Severity: minor
Tags: notabug
Found in version 26.1
Done: Michael Albinus <michael.albinus <at> gmx.de>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Phil Sainty <psainty <at> orcon.net.nz> writes:
Hi Phil,
>> `tramp-make-tramp-file-name' has never been documented as public
>> function, it is intended for internal use. Granted, this should have
>> been signalled better.
>
> Given the function naming, a NEWS entry seems warranted to me.
Well, this is a historical accident. None of the Tramp functions has
been indicated as internal (as a double slash in the function name would
do). This was already the case when I've entered the Tramp team back in
2002. And later on I resisted to perform a big renaming just for this.
> I do think that there *should* be a public interface for manipulating
> tramp file names. If these were never intended as such then perhaps
> such functionality could be introduced...
Perhaps. These days, people dissect a remote file name by the different
calls of `file-remote-p', and reconstruct the file name by `concat' or
`format'. An public interface might help. But this won't be
`tramp-make-tramp-file-name', because this is the internal working
horse, which will always be adapted to whatever need arrives in Tramp.
Maybe you could propose such a public interface? It shouldn't be Tramp
specific, other file name handlers shall profit from this as well. And
local file names as arguments shall also be possible, so that you could
change a local file name into a remote file name by a simple call (think
about the common case changing a local file name into a sudo'ed one).
See also function `file-local-name' (introduced in Emacs 26.1), which
could be part of such broader interface.
>> (setf (tramp-file-name-host vec) "whatever")
>
> Ah, I'd actually tried that in 25.2 but those are not generalized
> variables in that version. I see that it works in 26.1 though,
> so that's an excellent enhancement.
Well, `tramp-file-name' has been introduced as defstruct in Tramp
2.3. Before, there was no dedicated type, and VEC was always a, hmm,
simple vector.
> cheers,
> -Phil
Best regards, Michael.
This bug report was last modified 7 years and 50 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.