summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJohn Turner <jturner.usa@gmail.com>2025-10-27 01:10:42 -0400
committerJohn Turner <jturner.usa@gmail.com>2025-10-27 01:10:42 -0400
commite6037210c61b3da6d51faf0b4b1b4e3110274831 (patch)
tree31f8351d1efb28243acb8087465c2db7d667db49 /tests
parent191a3e2d48e153492e1480166a8511d0563c957c (diff)
downloadmon-e6037210c61b3da6d51faf0b4b1b4e3110274831.tar.gz
replace take_while and separated_list with list combinator
Diffstat (limited to 'tests')
-rw-r--r--tests/sexpr.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/sexpr.rs b/tests/sexpr.rs
index dd00b73..4434670 100644
--- a/tests/sexpr.rs
+++ b/tests/sexpr.rs
@@ -32,7 +32,8 @@ fn int<'a>() -> impl Parser<&'a str, Output = Sexpr> {
fn sexpr<'a>(it: InputIter<&'a str>) -> ParserResult<&'a str, Sexpr> {
sexpr
- .separated_list(whitespace())
+ .followed_by(whitespace())
+ .list(0..)
.delimited_by(tag("("), tag(")"))
.map(|output| Sexpr::List(output))
.or(atom())