unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: Glenn Morris <rgm@gnu.org>
Cc: 18891@debbugs.gnu.org
Subject: bug#18891: Doesn't handle pwd = /C: very well
Date: Tue, 04 Nov 2014 20:36:38 +0100	[thread overview]
Message-ID: <87k33alpvd.fsf@gmx.de> (raw)
In-Reply-To: <xqh9yerdak.fsf@fencepost.gnu.org> (Glenn Morris's message of "Tue, 04 Nov 2014 14:11:47 -0500")

Glenn Morris <rgm@gnu.org> writes:

> I don't consider a performance penalty an undesired side effect, but
> rather necessary to avoid a completely incorrect result, such as we have
> in this case.

The "unnecessary result" is an error in `file-attributes'.

>> (substitute-in-file-name "/C:/$FOO") requires the expansion of
>> $FOO. That's the task of Tramp, according to that file name. Nothing you
>> can check before invoking Tramp, because you don't know the value of $FOO.
>
> Why can't it be checked before Tramp?
>
> What if "FOO = foo" in the local environment, and "/C:/foo"
> is a real directory on the local machine?

`substitute-in-file-name' is an operation supporting file name
handlers. This handler must be called, instead of expanding an
environment variable locally. That's the design, and the promise by the
API.

Everything could be changed, of course. But please then with a
corresponding *design* change. And `substitute-in-file-name' was just
the very first example which came to my mind, without thinking about
seriously. There are many other operations supporting file name
handlers, which must be investigated for this kind of changes as well.

For the records: I do not oppose fundamentally such changes. I just
resist to change something on-the-fly, without redesign.

Best regards, Michael.





  reply	other threads:[~2014-11-04 19:36 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-29 20:02 bug#18891: Doesn't handle pwd = /C: very well Glenn Morris
2014-11-04 12:48 ` Michael Albinus
2014-11-04 16:47   ` Glenn Morris
2014-11-04 17:06     ` Eli Zaretskii
2014-11-04 17:36       ` Glenn Morris
2014-11-04 18:47         ` Michael Albinus
2014-11-04 18:58           ` Glenn Morris
2014-11-04 19:30             ` Michael Albinus
2014-11-04 19:11           ` Glenn Morris
2014-11-04 19:36             ` Michael Albinus [this message]
2014-11-04 20:24       ` Stefan Monnier
2014-11-05 11:25         ` Michael Albinus
2014-11-05 19:43           ` Glenn Morris
2014-11-05 19:45             ` Glenn Morris
2014-11-05 19:53               ` Eli Zaretskii
2014-11-05 20:07                 ` Michael Albinus
2014-11-05 19:56               ` Michael Albinus
2014-11-05 22:44                 ` Stefan Monnier
2014-11-06  3:50                   ` Eli Zaretskii
2014-11-06  8:33                     ` Michael Albinus
2014-11-06 15:39                       ` Stefan Monnier
2014-11-06 15:50                         ` Michael Albinus
2014-11-06 23:30                           ` Stefan Monnier
2014-11-07 10:38                             ` Andreas Schwab
2014-11-07 15:06                               ` Stefan Monnier
2014-11-07 18:54                                 ` Andreas Schwab
2014-11-08  4:35                                   ` Stefan Monnier
2014-11-08  8:13                                     ` Michael Albinus
2014-11-08  8:14                                     ` Andreas Schwab
2014-11-08 15:33                                       ` Stefan Monnier
2014-11-08 16:13                                         ` Andreas Schwab
2014-11-08 18:01                                           ` Stefan Monnier
2014-11-08 18:13                                             ` Andreas Schwab
2014-11-08 20:30                                               ` Stefan Monnier
2014-11-08 20:57                                                 ` Andreas Schwab
2014-11-08 22:03                                                   ` Stefan Monnier
2014-11-08 22:09                                                     ` Andreas Schwab
2014-11-08 22:25                                                       ` Stefan Monnier
2014-11-08 22:31                                                         ` Andreas Schwab
2014-11-09  3:26                                                           ` Stefan Monnier
2014-11-09  9:13                                         ` Michael Albinus
2014-11-09 14:23                                           ` Stefan Monnier
2014-11-09 19:50                                             ` Michael Albinus
2014-11-10 15:29                                               ` Stefan Monnier
2014-11-10 15:55                                                 ` Michael Albinus
2014-11-10 22:30                                                   ` Stefan Monnier
2014-11-11  8:42                                                     ` Michael Albinus
2014-11-11 17:09                                                       ` Stefan Monnier
2014-11-11 21:13                                                         ` Michael Albinus
2014-11-12  1:46                                                           ` Stefan Monnier
2014-11-12  7:50                                                             ` Michael Albinus
2014-11-15 19:21                                                               ` Glenn Morris
2014-11-16 10:19                                                                 ` Michael Albinus
2014-11-05 20:04             ` Michael Albinus
2014-11-05 20:22               ` Glenn Morris
2014-11-07 14:52             ` Michael Albinus
2014-11-07 15:14               ` Eli Zaretskii
2014-11-07 16:58                 ` Michael Albinus
2014-11-07 19:56                   ` Eli Zaretskii
2014-11-07 20:10                     ` Michael Albinus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k33alpvd.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=18891@debbugs.gnu.org \
    --cc=rgm@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).