GNU bug report logs -
#10939
24.0.94; backward-delete-char-untabify read-only error
Previous Next
Reported by: Leo <sdl.web <at> gmail.com>
Date: Sun, 4 Mar 2012 13:34:01 UTC
Severity: normal
Found in version 24.0.94
Done: Leo <sdl.web <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
1. (setq backward-delete-char-untabify-method 'hungry)
2. (setq enable-recursive-minibuffers t)
3. M-: and then type some spaces
4. M-x backward-delete-char-untabify
You should see something like:
delete-backward-char: Text is read-only
This patch fixes it:
diff --git a/lisp/simple.el b/lisp/simple.el
index c14d0d70..0faf54bc 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -3458,8 +3458,10 @@ (defun backward-delete-char-untabify (arg &optional killp)
((eq backward-delete-char-untabify-method 'all)
" \t\n\r")))
(n (if skip
- (let ((wh (- (point) (save-excursion (skip-chars-backward skip)
- (point)))))
+ (let* ((oldpt (point))
+ (wh (- oldpt (save-excursion
+ (skip-chars-backward skip)
+ (constrain-to-field nil oldpt)))))
(+ arg (if (zerop wh) 0 (1- wh))))
arg)))
;; Avoid warning about delete-backward-char
This bug report was last modified 13 years and 164 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.