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: List/String Conversion, Previous: String Predicates, Up: Strings [Contents][Index]
The string constructor procedures create new string objects, possibly initializing them with some specified character data. See also See String Selection, for ways to create strings from existing strings.
Return a newly allocated string made from the given character arguments.
(string #\x #\y #\z) ⇒ "xyz" (string) ⇒ ""
Return a newly allocated string made from a list of characters.
(list->string '(#\a #\b #\c)) ⇒ "abc"
Return a newly allocated string made from a list of characters, in reverse order.
(reverse-list->string '(#\a #\B #\c)) ⇒ "cBa"
Return a newly allocated string of length k. If chr is given, then all elements of the string are initialized to chr, otherwise the contents of the string are unspecified.
Like scm_make_string
, but expects the length as a
size_t
.
proc is an integer->char procedure. Construct a string of size len by applying proc to each index to produce the corresponding string element. The order in which proc is applied to the indices is not specified.
Append the string in the string list ls, using the string
delimiter as a delimiter between the elements of ls.
grammar is a symbol which specifies how the delimiter is
placed between the strings, and defaults to the symbol
infix
.
infix
Insert the separator between list elements. An empty string will produce an empty list.
strict-infix
Like infix
, but will raise an error if given the empty
list.
suffix
Insert the separator after every list element.
prefix
Insert the separator before each list element.
Next: List/String Conversion, Previous: String Predicates, Up: Strings [Contents][Index]