branch: elpa/evil-numbers
commit 5ddc167f28f75fa59e65f3167d12228c4d2c8a05
Author: Campbell Barton <ideasma...@gmail.com>
Commit: Campbell Barton <ideasma...@gmail.com>

    Fix compatibility for pos-bol/eol for emacs <29.1
---
 evil-numbers.el | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/evil-numbers.el b/evil-numbers.el
index 2d1d396c0f..609462aa9f 100644
--- a/evil-numbers.el
+++ b/evil-numbers.el
@@ -72,6 +72,19 @@
   ;; For `pcase-dolist'.
   (require 'pcase))
 
+
+;; ---------------------------------------------------------------------------
+;; ;; Compatibility
+
+(when (version< emacs-version "29.1")
+  (defsubst pos-bol (&optional n)
+    "Return the position at the line beginning."
+    (line-beginning-position n))
+  (defsubst pos-eol (&optional n)
+    "Return the position at the line end."
+    (line-end-position n)))
+
+
 ;; ---------------------------------------------------------------------------
 ;; Custom Variables
 

Reply via email to