From a4411bcc3919c2099934fd49664ee689460ebf80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Manuel=20Tom=C3=A1s?= Date: Fri, 1 May 2026 14:16:07 -0300 Subject: Update libraries --- str.lisp | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'str.lisp') diff --git a/str.lisp b/str.lisp index 3d88d11..c0caeb4 100644 --- a/str.lisp +++ b/str.lisp @@ -52,23 +52,3 @@ (format result "~a" (char-downcase (char str i))) (format result "~a" (char str i)))) (get-output-stream-string result))) - -(defun line-and-column (str index) - (let ((line 1) (column 1)) - (dotimes (i index) - (let ((c (char str i))) - (case c - (#\Newline - (incf line) - (setf column 1)) - (t (incf column))))) - (cons line column))) - -(defun context-window (str index &key (side-length 20)) - (let ((begin (max (- index side-length) 0)) - (end (min (+ index side-length) (length str))) - (result '())) - (push (subseq str begin index) result) - (push (elt str index) result) - (push (subseq str (1+ index) end) result) - result)) -- cgit v1.2.3