From: Mark Wooding Date: Sun, 26 Mar 2017 14:16:18 +0000 (+0100) Subject: src/lexer-impl.lisp: Set default `:keep-end' in `%skip-until' function. X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/sod/commitdiff_plain/d0be8052ee97b6d685ca9b73a4ccfa22ed04ccf5 src/lexer-impl.lisp: Set default `:keep-end' in `%skip-until' function. The parser-macro set this correctly, but the function didn't. --- diff --git a/src/lexer-impl.lisp b/src/lexer-impl.lisp index ffd522f..6a9b2ce 100644 --- a/src/lexer-impl.lisp +++ b/src/lexer-impl.lisp @@ -46,7 +46,8 @@ (defun show-char (char) (format nil "`~C'" char)) (t (format nil "<~(~:C~)>" char)))) -(defun %skip-until (scanner token-types &key keep-end) +(defun %skip-until (scanner token-types + &key (keep-end (not (null (cdr token-types))))) "This is the implementation of the `skip-until' parser." (do ((consumedp nil t)) ((member (token-type scanner) token-types)