Is there a better way to find the last output?

Jacek Podkanski via Sbcl-help <[email protected]> Sat, 23 May 2026 19:50:40 +0100
Newsgroups gmane.lisp.steel-bank.general
Message-ID <CAE9ibtprt3_kd_MT8Tz5vDppe_1UCoDi2Y_k9g15csMHNy0rxQ@mail.gmail.com>
--===============0144145583826236141==
Content-Type: multipart/alternative; boundary="000000000000e1c8ac0652809f2a"

--000000000000e1c8ac0652809f2a
Content-Type: text/plain; charset="UTF-8"

I am experimenting with a new testing method, and wonder if there is a
better way to find recent output?


(defun last-lines-of-output (n)
  (serapeum:take n
                 (serapeum:~> *standard-output*
                              swank::real-output-stream
                              swank/gray::data
                              swank/gray::stream-data-buffer
                              serapeum:lines)))

--000000000000e1c8ac0652809f2a
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: base64

PGRpdiBkaXI9Imx0ciI+PGRpdj5JIGFtIGV4cGVyaW1lbnRpbmcgd2l0aCBhIG5ldyB0ZXN0aW5n
IG1ldGhvZCwgYW5kIHdvbmRlciBpZiB0aGVyZSBpcyBhIGJldHRlciB3YXkgdG8gZmluZCByZWNl
bnQgb3V0cHV0PzwvZGl2PjxkaXY+PGJyPjwvZGl2PjxkaXY+PGJyPjwvZGl2PjxkaXY+KGRlZnVu
IGxhc3QtbGluZXMtb2Ytb3V0cHV0IChuKTwvZGl2PsKgIChzZXJhcGV1bTp0YWtlIG48YnI+wqAg
wqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAoc2VyYXBldW06fiZndDsgKnN0YW5kYXJkLW91dHB1dCo8
YnI+wqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgc3dhbms6OnJl
YWwtb3V0cHV0LXN0cmVhbTxicj7CoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDC
oCDCoCDCoCBzd2Fuay9ncmF5OjpkYXRhPGJyPsKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKg
IMKgIMKgIMKgIMKgIMKgIHN3YW5rL2dyYXk6OnN0cmVhbS1kYXRhLWJ1ZmZlcjxicj7CoCDCoCDC
oCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCBzZXJhcGV1bTpsaW5lcykpKTwv
ZGl2Pg0K
--000000000000e1c8ac0652809f2a--


--===============0144145583826236141==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


--===============0144145583826236141==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Sbcl-help mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sbcl-help

--===============0144145583826236141==--