This makes the format strings remarkably hairy, but that just adds to
the fun, right?
(dolist (o opts)
(let ((doc (opt-documentation o)))
(cond ((not o))
(dolist (o opts)
(let ((doc (opt-documentation o)))
(cond ((not o))
- ((not (opt-long-name o))
+ ((not (or (opt-short-name o)
+ (opt-long-name o)))
(when newlinep
(terpri stream)
(setf newlinep nil))
(when newlinep
(terpri stream)
(setf newlinep nil))
(doc
(setf newlinep t)
(pprint-logical-block (stream nil :prefix " ")
(doc
(setf newlinep t)
(pprint-logical-block (stream nil :prefix " ")
- (format stream "~:[ ~;-~:*~C,~] --~A"
+ (format stream "~:[ ~;-~:*~C~:[~;,~]~:*~]~@[ --~A~]"
(opt-short-name o)
(opt-long-name o))
(when (opt-arg-name o)
(opt-short-name o)
(opt-long-name o))
(when (opt-arg-name o)
- (format stream "~:[=~A~;[=~A]~]"
+ (format stream
+ "~:[~;[~]~:[~0@*~:[ ~;~]~*~;=~]~A~0@*~:[~;]~]"
(opt-arg-name o)))
(write-string " " stream)
(pprint-tab :line 30 1 stream)
(opt-arg-name o)))
(write-string " " stream)
(pprint-tab :line 30 1 stream)