summaryrefslogtreecommitdiff
path: root/lisp/simple.el
diff options
context:
space:
mode:
authorStefan Kangas <stefankangas@gmail.com>2022-09-20 09:28:46 +0200
committerStefan Kangas <stefankangas@gmail.com>2022-09-20 09:28:46 +0200
commit9035c20888736180f58becb5dedd3957470b5476 (patch)
tree02b23209d1f3207c6a28f5772821b5616f15eb0c /lisp/simple.el
parent1b77f1981d8aa107becf571939f01ae04ed16873 (diff)
downloademacs-9035c20888736180f58becb5dedd3957470b5476.tar.gz
emacs-9035c20888736180f58becb5dedd3957470b5476.tar.bz2
emacs-9035c20888736180f58becb5dedd3957470b5476.zip
Revert "Allow nil value for filter-buffer-substring-function"
This reverts commit a7c65fc6660878e244432a5b25fb3a4ff20e8604.
Diffstat (limited to 'lisp/simple.el')
-rw-r--r--lisp/simple.el9
1 files changed, 2 insertions, 7 deletions
diff --git a/lisp/simple.el b/lisp/simple.el
index 40df5695c35..1b9bf9fa6d8 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -5363,10 +5363,7 @@ These commands include \\[set-mark-command] and \\[start-kbd-macro]."
The function is called with the same 3 arguments (BEG END DELETE)
that `filter-buffer-substring' received. It should return the
buffer substring between BEG and END, after filtering. If DELETE is
-non-nil, it should delete the text between BEG and END from the buffer.
-
-The default value is `buffer-substring--filter', and nil means
-the same as the default.")
+non-nil, it should delete the text between BEG and END from the buffer.")
(defun filter-buffer-substring (beg end &optional delete)
"Return the buffer substring between BEG and END, after filtering.
@@ -5382,9 +5379,7 @@ Use `filter-buffer-substring' instead of `buffer-substring',
you want to allow filtering to take place. For example, major or minor
modes can use `filter-buffer-substring-function' to exclude text properties
that are special to a buffer, and should not be copied into other buffers."
- (funcall (or filter-buffer-substring-function
- #'buffer-substring--filter)
- beg end delete))
+ (funcall filter-buffer-substring-function beg end delete))
(defun buffer-substring--filter (beg end &optional delete)
"Default function to use for `filter-buffer-substring-function'.