chiark / gitweb /
src/optparse.lisp: Don't print options which have no help text.
authorMark Wooding <mdw@distorted.org.uk>
Sun, 4 Aug 2019 17:52:36 +0000 (18:52 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Sun, 4 Aug 2019 17:52:36 +0000 (18:52 +0100)
This seems better than crashing because nil isn't a thing that can have
characters extracted from it.

src/optparse.lisp

index 5268cda728f33c69f7c8c7e65c7acbdeaaa059b0..c901a9ec021df9ca42e7cadd6dfd503a4be6f4c0 100644 (file)
@@ -1004,7 +1004,7 @@ (defun show-options-help (opts &optional (stream *standard-output*))
               (pprint-logical-block (stream nil)
                 (print-text doc stream))
               (terpri stream))
-             (t
+             (doc
               (setf newlinep t)
               (pprint-logical-block (stream nil :prefix "  ")
                 (format stream "~:[   ~;-~:*~C,~] --~A"