From: "Drew Adams" <drew.adams@oracle.com>
To: "'Thierry Volpiatto'" <thierry.volpiatto@gmail.com>
Cc: 'Karl Fogel' <kfogel@red-bean.com>, 12507@debbugs.gnu.org
Subject: bug#12507: [debbugs-tracker] Processed: severity 12507 wishlist
Date: Sat, 29 Sep 2012 08:51:34 -0700 [thread overview]
Message-ID: <29382156B26B45EE84512961BC10CB44@us.oracle.com> (raw)
In-Reply-To: <87ehlkoobb.fsf@gmail.com>
> >> > The question about visiting the file is still open, though.
> >>
> >> I am using now the patch I sent here yesterday and it works
> >> really good, faster and do backups (numered) as expected.
> >> Hope it will be applied here in emacs because it DTRT.
> >>
> >> I don't understand what is the problem with "visiting the
> >> file". See in precedent post why it is not bad visiting the
> >> file. In the special case of bookmark-write-file, it is
> >> really not the problem.
> >
> > Your question is for Stefan. Your patch is equivalent to
> > the change I proposed originally: just replace
> > `write-region' with `write-file'.
>
> No, this is ineficient too, you write twice the same data.
How so? What am I missing? What part of `write-file' writes the same data
twice? All I see in the `write-file' definition, in terms of writing, is a call
to `save-buffer'.
> The important thing is writing directly to the buffer of file.
> For the backup thing, yes it is similar, but with unneeded steps,
Steps that you seem to claim constitute an additional disk write. I don't see
that. What part of `write-file' performs an extra disk write?
The only "extra" steps I see in `write-file' are setting the visited file name,
setting the buffer status to modified, checking that the file is
`file-writable-p', and setting `buffer-read-only' to nil. And running
`vc-find-file-hook'.
You are, I think, side-tracking the issue a bit. The question to be decided is
whether to allow backups. It is not whether to use `write-file', `save-buffer',
`basic-save-buffer', or something else. I don't really care exactly how it's
done. I have confidence it will be done efficiently if it is decided to be
done.
> going straight to save-buffer is better and faster IMO (of
> course if you have started writing data in the file buffer)
>
> But the worst thing is the actual version with write-region:
> Slow and backup broken.
I don't see that the current version is slow, either. But it certainly does not
provide for backing up. That is the question to be decided.
next prev parent reply other threads:[~2012-09-29 15:51 UTC|newest]
Thread overview: 54+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <87bogubqjy.fsf@gnu.org>
[not found] ` <handler.s.C.13485522721217.transcript@debbugs.gnu.org>
2012-09-25 13:53 ` bug#12507: [debbugs-tracker] Processed: severity 12507 wishlist Drew Adams
2012-09-26 2:53 ` Chong Yidong
2012-09-26 3:18 ` Drew Adams
2012-09-26 4:04 ` Stefan Monnier
2012-09-26 14:19 ` Drew Adams
2012-09-26 19:46 ` Stefan Monnier
2012-09-26 20:31 ` Drew Adams
2012-09-26 21:46 ` Karl Fogel
2012-09-26 22:26 ` Drew Adams
2012-09-26 23:36 ` Drew Adams
2012-09-27 15:48 ` Karl Fogel
2012-09-27 16:00 ` Drew Adams
2012-09-27 17:57 ` Karl Fogel
2012-09-27 18:32 ` Drew Adams
2012-09-27 3:24 ` Stefan Monnier
2012-09-24 18:41 ` bug#12507: 24.2.50; `bookmark-write-file': use `write-file', not `write-region', to get backups Drew Adams
2012-09-27 5:38 ` bug#12507: [debbugs-tracker] Processed: severity 12507 wishlist Thierry Volpiatto
2012-09-27 18:37 ` Drew Adams
2012-09-27 21:16 ` Thierry Volpiatto
2012-09-28 9:04 ` Thierry Volpiatto
2012-09-28 20:00 ` Drew Adams
2012-09-29 7:42 ` Thierry Volpiatto
2012-09-29 14:36 ` Drew Adams
2012-09-29 15:12 ` Thierry Volpiatto
2012-09-29 15:51 ` Drew Adams [this message]
2012-09-29 16:20 ` Thierry Volpiatto
2012-09-29 16:50 ` Drew Adams
2012-09-29 16:57 ` Thierry Volpiatto
2012-10-01 3:38 ` bug#12507: Option `(bookmark-)version-control': Use :tag so doc string matches menu Karl Fogel
2012-10-01 4:06 ` bug#12507: Option `(bookmark-)version-control': Use :tag so docstring " Drew Adams
2012-10-01 4:13 ` bug#12507: Have I mentioned how much I hate Debbugs? Karl Fogel
2012-10-01 4:50 ` Drew Adams
2012-10-01 21:23 ` Karl Fogel
2012-10-01 22:00 ` Drew Adams
2012-10-02 5:31 ` Thierry Volpiatto
2020-11-29 1:07 ` bug#12507: [debbugs-tracker] Processed: severity 12507 wishlist Karl Fogel
2012-09-27 8:36 ` bug#12507: `bookmark-write-file': use `write-file', not `write-region', to get backups Juri Linkov
2012-09-27 15:02 ` Drew Adams
2020-09-18 15:02 ` bug#12507: [debbugs-tracker] Processed: severity 12507 wishlist Lars Ingebrigtsen
2020-09-18 16:23 ` Drew Adams
2020-09-19 14:18 ` Lars Ingebrigtsen
2020-09-19 17:29 ` Drew Adams
2020-09-23 6:41 ` Karl Fogel
2020-09-23 13:34 ` Lars Ingebrigtsen
2020-09-23 16:23 ` Eli Zaretskii
2020-09-24 13:58 ` Lars Ingebrigtsen
2020-09-29 5:27 ` Karl Fogel
2020-09-29 14:29 ` Lars Ingebrigtsen
2020-09-23 14:27 ` Eli Zaretskii
2020-09-23 18:13 ` Drew Adams
2020-09-23 18:14 ` Drew Adams
2020-09-29 5:25 ` Karl Fogel
2020-09-29 15:45 ` Drew Adams
2020-11-29 0:28 ` Karl Fogel
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=29382156B26B45EE84512961BC10CB44@us.oracle.com \
--to=drew.adams@oracle.com \
--cc=12507@debbugs.gnu.org \
--cc=kfogel@red-bean.com \
--cc=thierry.volpiatto@gmail.com \
/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.