[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master b4ae102: Remove Emacs 19 workaround from cperl-mode.el
From: |
Stefan Kangas |
Subject: |
master b4ae102: Remove Emacs 19 workaround from cperl-mode.el |
Date: |
Wed, 10 Mar 2021 10:08:55 -0500 (EST) |
branch: master
commit b4ae1024832bf95fb957baf6f464d67b5a4972b6
Author: Stefan Kangas <stefan@marxist.se>
Commit: Stefan Kangas <stefan@marxist.se>
Remove Emacs 19 workaround from cperl-mode.el
* lisp/progmodes/cperl-mode.el (cperl-make-indent): Remove Emacs 19
workaround.
---
lisp/progmodes/cperl-mode.el | 22 ++++++----------------
1 file changed, 6 insertions(+), 16 deletions(-)
diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el
index 6b22228..649eff1 100644
--- a/lisp/progmodes/cperl-mode.el
+++ b/lisp/progmodes/cperl-mode.el
@@ -907,22 +907,12 @@ In regular expressions (including character classes):
(defun cperl-make-indent (column &optional minimum keep)
- "Makes indent of the current line the requested amount.
-Unless KEEP, removes the old indentation. Works around a bug in ancient
-versions of Emacs."
- (let ((prop (get-text-property (point) 'syntax-type)))
- (or keep
- (delete-horizontal-space))
- (indent-to column minimum)
- ;; In old versions (e.g., 19.33) `indent-to' would not inherit properties
- (and prop
- (> (current-column) 0)
- (save-excursion
- (beginning-of-line)
- (or (get-text-property (point) 'syntax-type)
- (and (looking-at "\\=[ \t]")
- (put-text-property (point) (match-end 0)
- 'syntax-type prop)))))))
+ "Indent from point with tabs and spaces until COLUMN is reached.
+MINIMUM is like in `indent-to', which see.
+Unless KEEP, removes the old indentation."
+ (or keep
+ (delete-horizontal-space))
+ (indent-to column minimum))
;; Probably it is too late to set these guys already, but it can help later:
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master b4ae102: Remove Emacs 19 workaround from cperl-mode.el,
Stefan Kangas <=