From: Rutger van Beusekom <[email protected]>
* doc/ref/api-peg.texi (PEG API Reference): Remove trailing whitespace.
---
doc/ref/api-peg.texi | 46 ++++++++++++++++++++++----------------------
1 file changed, 23 insertions(+), 23 deletions(-)
diff --git a/doc/ref/api-peg.texi b/doc/ref/api-peg.texi
index d34ddc64c..0214f7ff1 100644
--- a/doc/ref/api-peg.texi
+++ b/doc/ref/api-peg.texi
@@ -221,11 +221,11 @@ character (in normal PEGs nonterminals can only be
alphabetic).
For example, if we:
@lisp
-(define-peg-string-patterns
+(define-peg-string-patterns
"as <- 'a'+
bs <- 'b'+
as-or-bs <- as/bs")
-(define-peg-string-patterns
+(define-peg-string-patterns
"as-tag <-- 'a'+
bs-tag <-- 'b'+
as-or-bs-tag <-- as-tag/bs-tag")
@@ -271,9 +271,9 @@ For Example, if we:
@end lisp
Then:
@lisp
-(match-pattern as-or-bs "aabbcc") @result{}
+(match-pattern as-or-bs "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: aa>
-(match-pattern as-or-bs-tag "aabbcc") @result{}
+(match-pattern as-or-bs-tag "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: (as-or-bs-tag (as-tag aa))>
@end lisp
@@ -325,7 +325,7 @@ find a valid substring starting at index 0 and
@code{search-for-pattern} keeps
looking. They are both equally capable of ``parsing'' and ``matching''
given those constraints.
-@deffn {Scheme Procedure} match-pattern nonterm string
+@deffn {Scheme Procedure} match-pattern nonterm string
Parses @var{string} using the PEG stored in @var{nonterm}. If no match
was found, @code{match-pattern} returns false. If a match was found, a PEG
match record is returned.
@@ -344,19 +344,19 @@ nothing
@lisp
(define-peg-pattern as all (+ "a"))
-(match-pattern as "aabbcc") @result{}
+(match-pattern as "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: (as aa)>
(define-peg-pattern as body (+ "a"))
-(match-pattern as "aabbcc") @result{}
+(match-pattern as "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: aa>
(define-peg-pattern as none (+ "a"))
-(match-pattern as "aabbcc") @result{}
+(match-pattern as "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: ()>
(define-peg-pattern bs body (+ "b"))
-(match-pattern bs "aabbcc") @result{}
+(match-pattern bs "aabbcc") @result{}
#f
@end lisp
@end deffn
@@ -371,31 +371,31 @@ was found, a PEG match record is returned.
@lisp
(define-peg-pattern as body (+ "a"))
-(search-for-pattern as "aabbcc") @result{}
+(search-for-pattern as "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: aa>
-(search-for-pattern (+ "a") "aabbcc") @result{}
+(search-for-pattern (+ "a") "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: aa>
-(search-for-pattern "'a'+" "aabbcc") @result{}
+(search-for-pattern "'a'+" "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: aa>
(define-peg-pattern as all (+ "a"))
-(search-for-pattern as "aabbcc") @result{}
+(search-for-pattern as "aabbcc") @result{}
#<peg start: 0 end: 2 string: aabbcc tree: (as aa)>
(define-peg-pattern bs body (+ "b"))
-(search-for-pattern bs "aabbcc") @result{}
+(search-for-pattern bs "aabbcc") @result{}
#<peg start: 2 end: 4 string: aabbcc tree: bb>
-(search-for-pattern (+ "b") "aabbcc") @result{}
+(search-for-pattern (+ "b") "aabbcc") @result{}
#<peg start: 2 end: 4 string: aabbcc tree: bb>
-(search-for-pattern "'b'+" "aabbcc") @result{}
+(search-for-pattern "'b'+" "aabbcc") @result{}
#<peg start: 2 end: 4 string: aabbcc tree: bb>
(define-peg-pattern zs body (+ "z"))
-(search-for-pattern zs "aabbcc") @result{}
+(search-for-pattern zs "aabbcc") @result{}
#f
-(search-for-pattern (+ "z") "aabbcc") @result{}
+(search-for-pattern (+ "z") "aabbcc") @result{}
#f
-(search-for-pattern "'z'+" "aabbcc") @result{}
+(search-for-pattern "'z'+" "aabbcc") @result{}
#f
@end lisp
@end deffn
@@ -468,9 +468,9 @@ itself satisfies @var{tst}, @code{(list lst)} is returned
(this is a
flat list whose only element satisfies @var{tst}).
@lisp
-(context-flatten (lambda (x) (and (number? (car x)) (= (car x) 1))) '(2 2 (1 1
(2 2)) (2 2 (1 1)))) @result{}
+(context-flatten (lambda (x) (and (number? (car x)) (= (car x) 1))) '(2 2 (1 1
(2 2)) (2 2 (1 1)))) @result{}
(2 2 (1 1 (2 2)) 2 2 (1 1))
-(context-flatten (lambda (x) (and (number? (car x)) (= (car x) 1))) '(1 1 (1 1
(2 2)) (2 2 (1 1)))) @result{}
+(context-flatten (lambda (x) (and (number? (car x)) (= (car x) 1))) '(1 1 (1 1
(2 2)) (2 2 (1 1)))) @result{}
((1 1 (1 1 (2 2)) (2 2 (1 1))))
@end lisp
@@ -624,7 +624,7 @@ symbol for strings)..
(entry "nobody:x:65534:65534:nobody:/nonexistent:/bin/sh")
(entry "messagebus:x:103:107::/var/run/dbus:/bin/false"))
(peg:tree (match-pattern tag-passwd "one entry"))
-(tag-passwd
+(tag-passwd
(entry "one entry"))
@end lisp
@@ -841,7 +841,7 @@ number <-- [0-9]+")
(apply next-func (car first))
(apply next-func (car rest)))
;; form (sum (((product ...) "+") ((product ...) "+")) (product ...))
- (car
+ (car
(reduce ;; walk through the list and build a left-associative tree
(lambda (l r)
(list (list (cadr r) (car r) (apply next-func (car l)))
--
2.46.0