[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] trunk r116957: * src/insdel.c (prepare_to_modify_buffer_1)
From: |
Stefan Monnier |
Subject: |
[Emacs-diffs] trunk r116957: * src/insdel.c (prepare_to_modify_buffer_1): Cancel lock-file checks and |
Date: |
Wed, 09 Apr 2014 01:48:19 +0000 |
User-agent: |
Bazaar (2.6b2) |
------------------------------------------------------------
revno: 116957
revision-id: address@hidden
parent: address@hidden
committer: Stefan Monnier <address@hidden>
branch nick: trunk
timestamp: Tue 2014-04-08 21:48:07 -0400
message:
* src/insdel.c (prepare_to_modify_buffer_1): Cancel lock-file checks and
region handling (and don't call signal_before_change) if
inhibit_modification_hooks is set.
(signal_before_change): Don't check inhibit_modification_hooks any more.
* lisp/subr.el (with-silent-modifications): Don't bind deactivate-mark,
buffer-file-name, and buffer-file-truename any more.
modified:
etc/NEWS news-20100311060928-aoit31wvzf25yr1z-1
lisp/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1432
lisp/subr.el subr.el-20091113204419-o5vbwnq5f7feedwu-151
src/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1438
src/insdel.c insdel.c-20091113204419-o5vbwnq5f7feedwu-175
=== modified file 'etc/NEWS'
--- a/etc/NEWS 2014-04-07 20:54:16 +0000
+++ b/etc/NEWS 2014-04-09 01:48:07 +0000
@@ -71,6 +71,9 @@
* Incompatible Lisp Changes in Emacs 24.5
+** inhibit-modification-hooks now also inhibits lock-file checks as well as
+active region handling.
+
* Lisp Changes in Emacs 24.5
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2014-04-08 03:32:37 +0000
+++ b/lisp/ChangeLog 2014-04-09 01:48:07 +0000
@@ -1,3 +1,8 @@
+2014-04-09 Stefan Monnier <address@hidden>
+
+ * subr.el (with-silent-modifications): Don't bind deactivate-mark,
+ buffer-file-name, and buffer-file-truename any more.
+
2014-04-08 Leo Liu <address@hidden>
Use lexical-binding and require cl-lib.
=== modified file 'lisp/subr.el'
--- a/lisp/subr.el 2014-04-03 00:18:08 +0000
+++ b/lisp/subr.el 2014-04-09 01:48:07 +0000
@@ -3174,12 +3174,7 @@
`(let* ((,modified (buffer-modified-p))
(buffer-undo-list t)
(inhibit-read-only t)
- (inhibit-modification-hooks t)
- deactivate-mark
- ;; Avoid setting and removing file locks and checking
- ;; buffer's uptodate-ness w.r.t the underlying file.
- buffer-file-name
- buffer-file-truename)
+ (inhibit-modification-hooks t))
(unwind-protect
(progn
,@body)
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2014-04-08 12:34:30 +0000
+++ b/src/ChangeLog 2014-04-09 01:48:07 +0000
@@ -1,3 +1,10 @@
+2014-04-09 Stefan Monnier <address@hidden>
+
+ * insdel.c (prepare_to_modify_buffer_1): Cancel lock-file checks and
+ region handling (and don't call signal_before_change) if
+ inhibit_modification_hooks is set.
+ (signal_before_change): Don't check inhibit_modification_hooks any more.
+
2014-04-08 Daniel Colascione <address@hidden>
* alloc.c (sweep_symbols, mark_object): Assert that symbol
=== modified file 'src/insdel.c'
--- a/src/insdel.c 2014-03-26 15:57:13 +0000
+++ b/src/insdel.c 2014-04-09 01:48:07 +0000
@@ -1804,6 +1804,9 @@
else
base_buffer = current_buffer;
+ if (inhibit_modification_hooks)
+ return;
+
if (!NILP (BVAR (base_buffer, file_truename))
/* Make binding buffer-file-name to nil effective. */
&& !NILP (BVAR (base_buffer, filename))
@@ -1813,7 +1816,6 @@
/* If `select-active-regions' is non-nil, save the region text. */
/* FIXME: Move this to Elisp (via before-change-functions). */
if (!NILP (BVAR (current_buffer, mark_active))
- && !inhibit_modification_hooks
&& XMARKER (BVAR (current_buffer, mark))->buffer
&& NILP (Vsaved_region_selection)
&& (EQ (Vselect_active_regions, Qonly)
@@ -1924,9 +1926,6 @@
ptrdiff_t count = SPECPDL_INDEX ();
struct rvoe_arg rvoe_arg;
- if (inhibit_modification_hooks)
- return;
-
start = make_number (start_int);
end = make_number (end_int);
preserve_marker = Qnil;
@@ -1937,7 +1936,7 @@
specbind (Qinhibit_modification_hooks, Qt);
/* If buffer is unmodified, run a special hook for that case. The
- check for Vfirst_change_hook is just a minor optimization. */
+ check for Vfirst_change_hook is just a minor optimization. */
if (SAVE_MODIFF >= MODIFF
&& !NILP (Vfirst_change_hook))
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] trunk r116957: * src/insdel.c (prepare_to_modify_buffer_1): Cancel lock-file checks and,
Stefan Monnier <=