projects
/
kmrcl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
r5284: *** empty log message ***
[kmrcl.git]
/
strings.lisp
diff --git
a/strings.lisp
b/strings.lisp
index 66c587b6969e0ab5b24a6bec843e3ecff37ef24e..cadd1acc29c6891b8a36e269201b0957f947322d 100644
(file)
--- a/
strings.lisp
+++ b/
strings.lisp
@@
-7,7
+7,7
@@
;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Apr 2000
;;;;
;;;; Programmer: Kevin M. Rosenberg
;;;; Date Started: Apr 2000
;;;;
-;;;; $Id: strings.lisp,v 1.4
5 2003/06/20 08:35:22
kevin Exp $
+;;;; $Id: strings.lisp,v 1.4
7 2003/07/09 19:19:19
kevin Exp $
;;;;
;;;; This file, part of KMRCL, is Copyright (c) 2002 by Kevin M. Rosenberg
;;;;
;;;;
;;;; This file, part of KMRCL, is Copyright (c) 2002 by Kevin M. Rosenberg
;;;;
@@
-492,3
+492,14
@@
for characters in a string"
(character (string v))
(symbol (symbol-name v))
(otherwise (write-to-string v))))
(character (string v))
(symbol (symbol-name v))
(otherwise (write-to-string v))))
+
+(defun string-right-trim-one-char (char str)
+ (declare (simple-string str))
+ (let* ((len (length str))
+ (last (1- len)))
+ (declare (fixnum len last))
+ (if (char= char (schar str last))
+ (subseq str 0 last)
+ str)))
+
+