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

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

[nongnu] elpa/annotate 92434b63ff 323/372: - improved documentation and


From: ELPA Syncer
Subject: [nongnu] elpa/annotate 92434b63ff 323/372: - improved documentation and fixed indentation for a couple of local functions.
Date: Fri, 4 Feb 2022 16:59:15 -0500 (EST)

branch: elpa/annotate
commit 92434b63ff8fe40df2089cf59331c1e1f9dfcdf2
Author: cage <cage@localhost>
Commit: cage <cage@invalid>

    - improved documentation and fixed indentation for a couple of local 
functions.
---
 annotate.el | 53 +++++++++++++++++++++++++++--------------------------
 1 file changed, 27 insertions(+), 26 deletions(-)

diff --git a/annotate.el b/annotate.el
index a97d55c49c..42f1c407c7 100644
--- a/annotate.el
+++ b/annotate.el
@@ -629,13 +629,14 @@ specified by `from' and `to'."
                 ;; annotate a line that terminate at `eol'
                 ;;
                 ;; if  the line  contains no  text before  the newline
-                ;; annotate the next line with text, if any
+                ;; annotate the next line with text, if any.
                 ;;
                 ;; if the line contains a single annotation that spans
                 ;; the whole line update the existing annotation
                 ;;
-                ;; if  the line  contains no  annotation annotate  the
-                ;; whole line that terminate at `eol'
+                ;; if the  line contains  no annotation, or  more than
+                ;; one  annotation,  annotate   the  whole  line  that
+                ;; terminate at `eol'
                 (let* ((bol                     
(annotate-beginning-of-line-pos))
                        (annotations-on-the-line 
(annotate-annotations-overlay-in-range bol
                                                                                
        eol)))
@@ -2702,29 +2703,29 @@ Arguments:
               ;; filter-fn     see the docstring
               ;; matchp        non nil if (funcall filter-fn previous-token) 
is not nil
               (operator             (previous-token filter-fn annotation 
matchp)
-                                    (let ((look-ahead        
(annotate-summary-lexer t)))
-                                      (if 
(annotate-summary-query-parse-end-input-p look-ahead)
-                                          ;; end of input, recurse one more 
time
-                                          (annotate-summary-query-parse-note 
filter-fn
-                                                                             
annotation
-                                                                             
matchp)
-                                        (let ((look-ahead-symbol
-                                               
(annotate-summary-query-lexer-symbol look-ahead))
-                                              (look-ahead-string
-                                               
(annotate-summary-query-lexer-string look-ahead)))
-                                          (cond
-                                           ((not (cl-find look-ahead-symbol 
'(and or close-par)))
-                                            (signal 
'annotate-query-parsing-error
-                                                    (list (format (concat 
"Expecting for operator "
-                                                                          
"('and' or 'or') or \")\". "
-                                                                          
"found %S instead")
-                                                                  
look-ahead-string))))
-                                           (t
-                                            ;; found operator, recurse to 
search for rhs of rule
-                                            ;; NOTE OPERATOR NOTE
-                                            (annotate-summary-query-parse-note 
filter-fn
-                                                                               
annotation
-                                                                               
matchp))))))))
+               (let ((look-ahead        (annotate-summary-lexer t)))
+                 (if (annotate-summary-query-parse-end-input-p look-ahead)
+                     ;; end of input, recurse one more time
+                     (annotate-summary-query-parse-note filter-fn
+                                                        annotation
+                                                        matchp)
+                   (let ((look-ahead-symbol
+                          (annotate-summary-query-lexer-symbol look-ahead))
+                         (look-ahead-string
+                          (annotate-summary-query-lexer-string look-ahead)))
+                     (cond
+                      ((not (cl-find look-ahead-symbol '(and or close-par)))
+                       (signal 'annotate-query-parsing-error
+                               (list (format (concat "Expecting for operator "
+                                                     "('and' or 'or') or 
\")\". "
+                                                     "found %S instead")
+                                             look-ahead-string))))
+                      (t
+                       ;; found operator, recurse to search for rhs of rule
+                       ;; NOTE OPERATOR NOTE
+                       (annotate-summary-query-parse-note filter-fn
+                                                          annotation
+                                                          matchp))))))))
     (let* ((look-ahead (annotate-summary-lexer t))) ; the next token that the 
lexer *will* consume
                                                     ; note the second arg is 
non nil
       (if (not (annotate-summary-query-parse-end-input-p look-ahead))



reply via email to

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