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

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

[elpa] master 31388e6 52/60: Add -s aliases


From: Junpeng Qiu
Subject: [elpa] master 31388e6 52/60: Add -s aliases
Date: Tue, 25 Oct 2016 17:45:16 +0000 (UTC)

branch: master
commit 31388e685ad1492a50cfd32cb5cfac396d84f532
Author: Junpeng Qiu <address@hidden>
Commit: Junpeng Qiu <address@hidden>

    Add -s aliases
---
 parsec.el |   12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/parsec.el b/parsec.el
index 44ac6c6..8ffb13d 100644
--- a/parsec.el
+++ b/parsec.el
@@ -707,6 +707,8 @@ This combinator fails if one of the parsers fails.")
   "Collect the results of all the parsers FORMS as a string."
   `(parsec-list-to-string (parsec-collect ,@forms)))
 
+(defalias 'parsec-collect-s 'parsec-collect-as-string)
+
 (defmacro parsec-start (&rest forms)
   "Eval the parsers FORMS and return the results or a `parsec-error'.
 This combinator should be used at the top level as the entry
@@ -797,10 +799,14 @@ point of your parsing program."
   "Apply the PARSER zero or more times and return the results as a string."
   `(mapconcat #'identity (parsec-many ,parser) ""))
 
+(defalias 'parsec-many-s 'parsec-many-as-string)
+
 (defmacro parsec-many1-as-string (parser)
   "Apply the PARSER one or more times and return the results as a string."
   `(mapconcat #'identity (parsec-many1 ,parser) ""))
 
+(defalias 'parsec-many1-s 'parsec-many1-as-string)
+
 (defmacro parsec-many-till (parser end &optional type)
   "Apply PARSER zero or more times until END succeeds.
 The return value is determined by TYPE.  If TYPE is `:both', return
@@ -840,6 +846,8 @@ meaning as `parsec-many-till'."
      (t
       `(parsec-list-to-string (parsec-many-till ,parser ,end ,type))))))
 
+(defalias 'parsec-many-till-s 'parsec-many-till-as-string)
+
 (defmacro parsec-until (parser &optional type)
   "Parse any characters until PARSER succeeds.
 TYPE has the same meaning as `parsec-many-till'."
@@ -851,6 +859,8 @@ Return the result of either part as a string.  TYPE has the 
same
 meaning as `parsec-many-till'."
   `(parsec-many-till-as-string (parsec-any-ch) ,parser ,type))
 
+(defalias 'parsec-until-s 'parsec-until-as-string)
+
 (defmacro parsec-not-followed-by (parser)
   "Succeed only when PARSER fails.  Consume no input."
   (let ((res-sym (make-symbol "results")))
@@ -897,6 +907,8 @@ Return a list of N values returned by PARSER."
 Return the N values returned by PARSER as a string."
   `(parsec-list-to-string (parsec-count ,n ,parser)))
 
+(defalias 'parsec-count-s 'parsec-count-as-string)
+
 (defmacro parsec-option (opt parser)
   "Try to apply PARSER and return OPT if PARSER fails without comsuming input."
   `(parsec-or ,parser ,opt))



reply via email to

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