aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcolin <colin@cicadas.surf>2023-09-10 11:33:06 -0700
committercolin <colin@cicadas.surf>2023-09-10 11:33:06 -0700
commitb1d927635d4a15d4904080bc9738799fb4873fff (patch)
tree1b7f570cbc2dcd4798f69f94955ac368a63520de
parente321e737d6c84251bb33fd4d7867b6f6aa6d62a5 (diff)
changed doc convention for optionals
-rw-r--r--argot.lisp2
-rw-r--r--docgen.lisp3
2 files changed, 2 insertions, 3 deletions
diff --git a/argot.lisp b/argot.lisp
index 3a077f0..8ab90ba 100644
--- a/argot.lisp
+++ b/argot.lisp
@@ -147,7 +147,7 @@ and it returns VAR in that case."
(princ "(A|B|...) One of the alternavites a b ...") (terpri)
(princ "PATTERN+ One or more PATTERN") (terpri)
(princ "PATTERN* Zero or more PATTERN") (terpri)
- (princ "[OPT] Zero or one of OPT"))))
+ (princ "OPT? Zero or one of OPT"))))
`(progn
(setf (get ',name 'argot::grammar-property)
(make-instance 'grammar
diff --git a/docgen.lisp b/docgen.lisp
index 4475576..db69cf7 100644
--- a/docgen.lisp
+++ b/docgen.lisp
@@ -17,9 +17,8 @@
(princ " " ))))
(defun write-optional-doc (arg)
- (princ "[")
(write-pattern-doc arg)
- (princ "]"))
+ (princ "?"))
(defun write-kleene-doc (arg)
(write-pattern-doc arg)