From: "Drew Adams" <drew.adams@oracle.com>
Cc: Stephen Leake <stephen_leake@member.fsf.org>,
Eli Zaretskii <eliz@gnu.org>, Chris Moore <dooglus@gmail.com>,
miles@gnu.org
Subject: RE: abbreviate-file-name on Windows seems incorrect
Date: Sun, 7 Jan 2007 18:04:27 -0800 [thread overview]
Message-ID: <EIENLHALHGIMHGDOLMIMIECICOAA.drew.adams@oracle.com> (raw)
In-Reply-To: <m2ps9qi9e4.fsf@gmail.com>
> The value of HOME is cached the first time abbreviate-file-name is
> called, and never updated, using exactly the code you quoted here:
>
> > The code for `abbreviate-file-name' defines `abbreviated-home-dir' as
> > follows, in order to be able to "substitute `~' for the user's home
> > directory", as the doc string says:
> >
> > (or abbreviated-home-dir
> > (setq abbreviated-home-dir
> > (let ((abbreviated-home-dir "$foo"))
> > (concat "^" (abbreviate-file-name
> > (expand-file-name "~"))
> > "\\(/\\|\\'\\)"))))
> >
> > The comment for this code is as follows, which indicates that a slash is
> > added to distinguish the home dir from a file in that dir:
>
> If you look up 3 lines from that comment about the slash, you'll see:
>
> ;; Compute and save the abbreviated homedir name.
> ;; We defer computing this until the first time it's needed,
Right. I saw that (but forgot about it - thanks for reminding me).
I think that's a mistake. What's gained by that? We already saw what is lost
by it.
BTW, the comment about deferring computation seems off base. I don't see any
computation deferral, but I do see computation caching. That's what is
important (and wrong), I think: `abbreviated-home-dir' is computed only
once.
next prev parent reply other threads:[~2007-01-08 2:04 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-06 7:56 abbreviate-file-name on Windows seems incorrect Drew Adams
2007-01-06 11:37 ` Lennart Borgman (gmail)
2007-01-06 14:18 ` Eli Zaretskii
2007-01-06 15:03 ` Lennart Borgman (gmail)
2007-01-06 11:56 ` Eli Zaretskii
2007-01-06 16:22 ` Drew Adams
2007-01-06 21:51 ` Eli Zaretskii
2007-01-06 22:42 ` Drew Adams
2007-01-07 2:44 ` Miles Bader
2007-01-07 4:12 ` Eli Zaretskii
2007-01-07 14:29 ` Stephen Leake
2007-01-07 20:47 ` Eli Zaretskii
2007-01-07 22:03 ` Drew Adams
2007-01-07 22:08 ` Drew Adams
2007-01-08 1:40 ` Chris Moore
2007-01-08 2:04 ` Drew Adams [this message]
2007-01-08 10:15 ` Jason Rumney
2007-01-08 16:29 ` Drew Adams
2007-01-09 0:01 ` Richard Stallman
2007-01-09 0:30 ` Jason Rumney
2007-01-09 12:55 ` Stephen Leake
2007-01-09 17:57 ` Richard Stallman
2007-01-08 8:44 ` Stephen Leake
2007-01-08 13:07 ` Chris Moore
2007-01-08 19:30 ` Eli Zaretskii
2007-01-09 12:52 ` Stephen Leake
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=EIENLHALHGIMHGDOLMIMIECICOAA.drew.adams@oracle.com \
--to=drew.adams@oracle.com \
--cc=dooglus@gmail.com \
--cc=eliz@gnu.org \
--cc=miles@gnu.org \
--cc=stephen_leake@member.fsf.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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.