diff --git a/src/streams.lisp b/src/streams.lisp index 8ee027e..a8742cf 100644 --- a/src/streams.lisp +++ b/src/streams.lisp @@ -14,6 +14,11 @@ (setf (output-column s) (- (length seq) newline-pos 1)))) (write-sequence seq (slot-value s 'understream) :start start :end end)) +(defmethod trivial-gray-streams:stream-line-column + ((s column-counting-output-stream)) + "Tell column number that stream S is currently at." + (output-column s)) + (defmethod trivial-gray-streams:stream-start-line-p ((s column-counting-output-stream)) "Tell if stream S is already at start of fresh new line." diff --git a/test/basic.lisp b/test/basic.lisp index 5dcb091..507b9cb 100644 --- a/test/basic.lisp +++ b/test/basic.lisp @@ -139,6 +139,14 @@ )) (values)) +(deftest slightly-verbose-test () + (format *error-output* "~&Watch out for me") + (is t)) + +(deftest slightly-verbose-test-2 () + (format *error-output* "...And me") + (is t)) + (deftest lambda-list-processing () (is (equal (lambda-list-to-value-list-expression '(p1 p2 &optional o1 (o2 "o2") &key k1 (k2 "k2") &allow-other-keys)) '(list (cons 'p1 p1) (cons 'p2 p2) (cons 'o1 o1) (cons 'o2 o2) (cons 'k1 k1)