From dcff69e9d6334c57faa5a690c449f12969a6526f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Manuel=20Tom=C3=A1s?= Date: Mon, 9 Jun 2025 02:51:29 -0300 Subject: Revert "Remove separated-list" This reverts commit 2556460ea3fb9d52db1f24b287b35dc7b0f62cab. --- extra.lisp | 8 ++++++++ package.lisp | 3 ++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/extra.lisp b/extra.lisp index 6453751..b738da7 100644 --- a/extra.lisp +++ b/extra.lisp @@ -42,3 +42,11 @@ (defparameter whitespace (optional (many (unit whitespace?)))) + +(defun separated-list (p separator) + (comp ((v p) + (sep (optional separator)) + (vn (if sep + (separated-list p separator) + nothing))) + (cons v vn))) diff --git a/package.lisp b/package.lisp index 7067dfb..2b64c6f 100644 --- a/package.lisp +++ b/package.lisp @@ -16,4 +16,5 @@ #:many #:repeat #:whitespace? - #:whitespace)) + #:whitespace + #:separated-list)) -- cgit v1.2.3