emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master d5cb3cb: Make erc expand the final abbrev


From: Lars Ingebrigtsen
Subject: master d5cb3cb: Make erc expand the final abbrev
Date: Fri, 16 Oct 2020 11:36:32 -0400 (EDT)

branch: master
commit d5cb3cb9a45dd9028789e10088a6ca491c370d10
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>

    Make erc expand the final abbrev
    
    * lisp/erc/erc.el (erc-send-current-line): Expand abbrevs at the
    end of lines (bug#42854).
---
 lisp/erc/erc.el | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el
index 1d5506e..6481446 100644
--- a/lisp/erc/erc.el
+++ b/lisp/erc/erc.el
@@ -5472,6 +5472,10 @@ submitted line to be intentional."
             (time-less-p erc-accidental-paste-threshold-seconds
                         (time-subtract now erc-last-input-time)))
         (save-restriction
+          ;; If there's an abbrev at the end of the line, expand it.
+          (when (and abbrev-mode
+                     (eolp))
+            (expand-abbrev))
           (widen)
           (if (< (point) (erc-beg-of-input-line))
               (erc-error "Point is not in the input area")



reply via email to

[Prev in Thread] Current Thread [Next in Thread]