projects
/
jscl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
791e881
)
concatenate-two
author
David Vázquez
<davazp@gmail.com>
Fri, 24 May 2013 01:25:35 +0000
(
02:25
+0100)
committer
David Vázquez
<davazp@gmail.com>
Fri, 24 May 2013 01:25:35 +0000
(
02:25
+0100)
src/string.lisp
patch
|
blob
|
history
diff --git
a/src/string.lisp
b/src/string.lisp
index
7e9ae1e
..
6f88024
100644
(file)
--- a/
src/string.lisp
+++ b/
src/string.lisp
@@
-53,3
+53,16
@@
(list g!value)
`(aset ,g!string ,g!index ,g!value)
`(char ,g!string ,g!index))))
+
+(defun concatenate-two (string1 string2)
+ (let* ((len1 (length string1))
+ (len2 (length string2))
+ (string (make-array (+ len1 len2) :element-type 'character))
+ (i 0))
+ (dotimes (j len1)
+ (aset string i (char string1 j))
+ (incf i))
+ (dotimes (j len2)
+ (aset string i (char string2 j))
+ (incf i))
+ string))