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

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

[nongnu] elpa/helm ae75e885a6: Fix helm-info--node-regexp


From: ELPA Syncer
Subject: [nongnu] elpa/helm ae75e885a6: Fix helm-info--node-regexp
Date: Wed, 14 Sep 2022 03:58:55 -0400 (EDT)

branch: elpa/helm
commit ae75e885a647bd3cf47b1851da0ffaf52d9fa8a1
Author: Thierry Volpiatto <thievol@posteo.net>
Commit: Thierry Volpiatto <thievol@posteo.net>

    Fix helm-info--node-regexp
---
 helm-info.el | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/helm-info.el b/helm-info.el
index e996c09634..500e545fb4 100644
--- a/helm-info.el
+++ b/helm-info.el
@@ -100,7 +100,7 @@ Argument TOBUF is the `helm-candidate-buffer'."
   (helm-goto-line (cdr node-line)))
 
 (defvar helm-info--node-regexp
-  "^\\* +\\(.+\\):[ \\t]+\\(.*\\)\\(?:[ \\t]*\\)(line +\\([0-9]+\\))"
+  "^\\* +\\(.+\\):[[:space:]]+\\(.*\\)\\(?:[[:space:]]*\\)(line +\\([0-9]+\\))"
   "A regexp that should match file name, node name and line number in
 a line like this:
 
@@ -109,17 +109,18 @@ a line like this:
 (defun helm-info-display-to-real (line)
   "Transform LINE to an acceptable argument for `info'.
 If line have a node use the node, otherwise use directly first name found."
-  (let (nodename linum)
+  (let ((info-file (helm-get-attr 'info-file))
+        nodename linum)
     (when (string-match helm-info--node-regexp line)
       (setq nodename (match-string 2 line)
             linum    (match-string 3 line)))
     (if nodename
         (cons (format "(%s)%s"
-                      (helm-get-attr 'info-file)
+                      info-file
                       (replace-regexp-in-string ":\\'" "" nodename))
               (string-to-number (or linum "1")))
       (cons (format "(%s)%s"
-                    (helm-get-attr 'info-file)
+                    info-file
                     (helm-aand (replace-regexp-in-string "^* " "" line)
                                (replace-regexp-in-string "::?.*\\'" "" it)))
             1))))



reply via email to

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