Strings

STK string constants allow the insertion of arbitrary characters by encoding them as escape sequences, introduced by a backslash (\). The valid escape sequences are shown in Table 2. For instance, the string

$\Longrightarrow$
$\Longrightarrow$ unspecified error makeotherˆ`=̀13`


          gobblecr"ab\040c\nd\e"
is the string consisting of the characters #\a, #\b,#\space, #\c, #\newline, #\d and #\e.


Table: String escape sequences
Sequence Character inserted
\b Backspace
\e Escape
\n Newline
\t Horizontal Tab
\n Carriage Return
\0abc ASCII character with octal value abc
\<newline> None (permits to enter a string on several lines)
\<other> <other>






`=̀13`(ndexfile(index-entry "string?" "tt" main )string?obj)
procedure
`=̀13`(ndexfile(index-entry "make-string" "tt" main )make-stringk)
procedure
`=̀13`(ndexfile(index-entry "make-string" "tt" main )make-stringk char)
procedure
`=̀13`(ndexfile(index-entry "string" "tt" main )stringchar … )
procedure
`=̀13`(ndexfile(index-entry "string-length" "tt" main )string-lengthstring)
procedure
`=̀13`(ndexfile(index-entry "string-ref" "tt" main )string-refstring k)
procedure
`=̀13`(ndexfile(index-entry "string-set!" "tt" main )string-set!string k char)
procedure
`=̀13`(ndexfile(index-entry "string=?" "tt" main )string=?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string-ci=?" "tt" main )string-ci=?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string<?" "tt" main )string<?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string>?" "tt" main )string>?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string<=?" "tt" main )string<=?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string>=?" "tt" main )string>=?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string-ci<?" "tt" main )string-ci<?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string-ci>?" "tt" main )string-ci>?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string-ci<=?" "tt" main )string-ci<=?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "string-ci>=?" "tt" main )string-ci>=?string1 string2)
procedure
`=̀13`(ndexfile(index-entry "substring" "tt" main )substringstring start end)
procedure
`=̀13`(ndexfile(index-entry "string-append" "tt" main )string-appendstring … )
procedure
`=̀13`(ndexfile(index-entry "string->list" "tt" main )string->liststring)
procedure
`=̀13`(ndexfile(index-entry "list->string" "tt" main )list->stringchars)
procedure
`=̀13`(ndexfile(index-entry "string-copy" "tt" main )string-copystring)
procedure
`=̀13`(ndexfile(index-entry "string-fill!" "tt" main )string-fill!string char)
procedure
Identical to R4RS.





`=̀13`(ndexfile(index-entry "string-find?" "tt" main )string-find?string1 string2)
procedure
Returns #t if string1 appears somewhere in string2; otherwise returns #f.





`=̀13`(ndexfile(index-entry "string-index" "tt" main )string-indexstring1 string2)
procedure
Returns the index of where string1 is a substring of string2 if it exists; returns #f otherwise. $\Longrightarrow$
$\Longrightarrow$ unspecified error makeotherˆ`=̀13`


          gobblecr(string-index "ca" "abracadabra") 4(string-index "ba" "abracadabra") #f





`=̀13`(ndexfile(index-entry "string-lower" "tt" main )string-lowerstring)
procedure
Returns a string in which all upper case letters of ndexfile(index-entry "string" "tt" aux )string have been replaced by their lower case equivalent.





`=̀13`(ndexfile(index-entry "string-upper" "tt" main )string-upperstring)
procedure
Returns a string in which all lower case letters of ndexfile(index-entry "string" "tt" aux )string have been replaced by their upper case equivalent.