diff options
| author | 2025-10-18 08:19:45 +0300 | |
|---|---|---|
| committer | 2025-10-18 08:19:45 +0300 | |
| commit | a802a63364721a2da95b75bc8ab19abfa4888373 (patch) | |
| tree | c4a197592df54ea722be9592238914be86f8e266 /src/strings.lisp | |
| parent | Get rid of anaphora (diff) | |
| download | ukkoclot-a802a63364721a2da95b75bc8ab19abfa4888373.tar.gz ukkoclot-a802a63364721a2da95b75bc8ab19abfa4888373.tar.xz ukkoclot-a802a63364721a2da95b75bc8ab19abfa4888373.zip | |
Bunch more tiny improvements
Diffstat (limited to 'src/strings.lisp')
| -rw-r--r-- | src/strings.lisp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/strings.lisp b/src/strings.lisp index f08010e..b1b4f00 100644 --- a/src/strings.lisp +++ b/src/strings.lisp | |||
| @@ -34,7 +34,7 @@ | |||
| 34 | (#\> (write-string ">" out)) | 34 | (#\> (write-string ">" out)) |
| 35 | (#\& (write-string "&" out)) | 35 | (#\& (write-string "&" out)) |
| 36 | (#\" (write-string """ out)) | 36 | (#\" (write-string """ out)) |
| 37 | (t (write-char ch out))))) | 37 | (otherwise (write-char ch out))))) |
| 38 | 38 | ||
| 39 | (defun is-tg-whitespace (ch) | 39 | (defun is-tg-whitespace (ch) |
| 40 | (let ((gc (general-category ch))) | 40 | (let ((gc (general-category ch))) |
| @@ -65,14 +65,14 @@ | |||
| 65 | (loop for ch across str do | 65 | (loop for ch across str do |
| 66 | (case ch | 66 | (case ch |
| 67 | (#\- (write-char #\_ out)) | 67 | (#\- (write-char #\_ out)) |
| 68 | (t (write-char ch out)))))) | 68 | (otherwise (write-char ch out)))))) |
| 69 | 69 | ||
| 70 | (defun snake->lisp-case (str) | 70 | (defun snake->lisp-case (str) |
| 71 | (with-output-to-string (out) | 71 | (with-output-to-string (out) |
| 72 | (loop for ch across str do | 72 | (loop for ch across str do |
| 73 | (case ch | 73 | (case ch |
| 74 | (#\_ (write-char #\- out)) | 74 | (#\_ (write-char #\- out)) |
| 75 | (t (write-char ch out)))))) | 75 | (otherwise (write-char ch out)))))) |
| 76 | 76 | ||
| 77 | (defun starts-with (str prefix) | 77 | (defun starts-with (str prefix) |
| 78 | (and (> (length str) (length prefix)) | 78 | (and (> (length str) (length prefix)) |