Warning: This is the manual of the legacy Guile 2.2 series. You may want to read the manual of the current stable series instead.
Next: String Comparison, Previous: String Selection, Up: Strings [Contents][Index]
These procedures are for modifying strings in-place. This means that the result of the operation is not a new string; instead, the original string’s memory representation is modified.
Store chr in element k of str and return an unspecified value. k must be a valid index of str.
Like scm_string_set_x
, but the index is given as a size_t
.
Stores chr in every element of the given str and returns an unspecified value.
Change every character in str between start and end to fill.
(define y (string-copy "abcdefg")) (substring-fill! y 1 3 #\r) y ⇒ "arrdefg"
Copy the substring of str1 bounded by start1 and end1 into str2 beginning at position start2. str1 and str2 can be the same string.
Copy the sequence of characters from index range [start, end) in string s to string target, beginning at index tstart. The characters are copied left-to-right or right-to-left as needed – the copy is guaranteed to work, even if target and s are the same string. It is an error if the copy operation runs off the end of the target string.
Next: String Comparison, Previous: String Selection, Up: Strings [Contents][Index]