[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
vc.el macros bind variables
From: |
Kalle Olavi Niemitalo |
Subject: |
vc.el macros bind variables |
Date: |
11 Nov 2001 12:58:30 +0200 |
In GNU Emacs 21.1.1 (i386-debian-linux-gnu, X toolkit, Xaw3d scroll bars)
of 2001-10-29 on Astalo, modified by Debian
configured using `configure i386-debian-linux-gnu --prefix=/usr
--sharedstatedir=/var/lib --libexecdir=/usr/lib --localstatedir=/var/lib
--infodir=/usr/share/info --mandir=/usr/share/man --with-pop=yes --with-x=yes
--with-x-toolkit=athena'
Important settings:
value of $LC_ALL: nil
value of $LC_COLLATE: nil
value of $LC_CTYPE: nil
value of $LC_MESSAGES: nil
value of $LC_MONETARY: nil
value of $LC_NUMERIC: nil
value of $LC_TIME: nil
value of $LANG: fi_FI
locale-coding-system: iso-latin-1
default-enable-multibyte-characters: t
Some macros in vc.el put caller-supplied forms inside `let'
bindings of variables that the caller might use:
- `with-vc-properties' binds `filename'.
- `with-vc-file' binds `file'.
- `edit-vc-file' uses `with-vc-file'.
For example, this code adds "/home/kalle/IMUTA" and not "berlin.deb":
(let ((file "berlin.deb"))
(edit-vc-file "~/IMUTA"
(format "Added %s" file)
(goto-char (point-max))
(unless (bolp) (insert ?\n))
(insert file ?\n)))
`with-vc-properties' is used from vc.el only, and none of the
callers uses `filename', so the problem is not very serious.
It would be prudent to mention it in the docstring, though.
However, `with-vc-file' and `edit-vc-file' are autoloaded and not
used in the rest of Emacs, so they are obviously meant to be
called from user programs. I think they should use a funny-named
variable (such as vc-file-internal) or gensym.
Also, the documentation string of `with-vc-properties' is unclear
about whether the `file' and `settings' arguments are evaluated.
Recent input:
<return> <return> <return> <return> <return> <return>
<down> <return> <down> <return> <return> SPC <backspace>
<return> <return> <return> <return> <return> <return>
<return> <return> <return> <return> <return> <return>
<return> <return> <return> <down> <return> <down> <return>
<return> <return> <return> <return> <return> <return>
<return> <return> <return> <return> <return> <return>
<return> <down> <return> q s g q y <down> <down> <down>
<down> <down> <down> <down> <down> <down> <down> <down>
<next> <up> <up> <up> <up> <up> <up> <up> <up> <up>
<up> <up> <up> <up> <prior> <prior> <next> M-x r e
p o r t SPC e m a c s SPC b u f <backspace> g <ret
urn>
Recent messages:
Saving /home/kalle/.newsrc.eld...done
Reading active file from news via nntp...
Reading active file via nnml...
nnml: Reading incoming mail from file...
nnml: Reading incoming mail (no new mail)...done
Reading active file via nnml...done
Checking new news...done
(No changes need to be saved)
Loading emacsbug...done
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- vc.el macros bind variables,
Kalle Olavi Niemitalo <=