1 USING: help.markup help.syntax io math strings ;
5 { $values { "str" string } }
6 { $description "String interpolation using named variables and/or stack arguments, writing to the " { $link output-stream } "." }
7 { $notes "Stack arguments are numbered from the top of the stack, or provided anonymously by order of arguments." }
10 "USING: interpolate ;"
11 "\"Bob\" \"Alice\" \"Hi ${1}, it's ${0}.\" interpolate"
15 "USING: interpolate namespaces ;"
16 "\"Fred\" \"name\" [ \"Hi ${name}\" interpolate ] with-variable"
20 "USING: interpolate ;"
21 "\"Mr.\" \"Anderson\"" "\"Hello, ${} ${}\" interpolate"
26 HELP: interpolate>string
27 { $values { "str" string } { "newstr" string } }
28 { $description "String interpolation using named variables and/or stack arguments, captured as a " { $link string } "." }
29 { $notes "Stack arguments are numbered from the top of the stack, or provided anonymously by order of arguments." } ;
31 { interpolate interpolate>string } related-words