emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/ftable a647832 03/14: xx


From: Stefan Monnier
Subject: [elpa] externals/ftable a647832 03/14: xx
Date: Mon, 2 Aug 2021 18:27:31 -0400 (EDT)

branch: externals/ftable
commit a647832418e4a36392f27157fbccc1ade1f8525f
Author: Yuan Fu <casouri@gmail.com>
Commit: Yuan Fu <casouri@gmail.com>

    xx
---
 ftable.el | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/ftable.el b/ftable.el
index 6c33b9f..57c0beb 100644
--- a/ftable.el
+++ b/ftable.el
@@ -550,12 +550,14 @@ position of the table, not including any newlines. TABLEP 
is t if
 point is on a table, nil if not. CHARSET is the box drawing
 charset used by the table (if there is a table).
 \(See `ftable-box-charset-alist'.)"
-  (let* ((beg (save-excursion (search-backward "\n\n" nil t)
+  (let* ((beg (save-excursion (if (not (search-backward "\n\n" nil t))
+                                  (point-min))
                               (skip-chars-forward "\n")
                               (point)))
-         (end (save-excursion (search-forward "\n\n" nil t)
-                              (skip-chars-backward "\n")
-                              (point)))
+         (end (save-excursion (if (not (search-forward "\n\n" nil t))
+                                  (point-max)
+                                (skip-chars-backward "\n")
+                                (point))))
          (text (buffer-substring-no-properties
                 beg end)))
     (append (list text beg end)



reply via email to

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