For the complete Mojo documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /docs/manual/basics.md).
get_static_string
def get_static_string[string: StringSpan[ImmStaticOrigin], *extra: StringSpan[ImmStaticOrigin]]() -> StaticString
Form a StaticString from compile-time StringSpan values. This guarantees that the returned string is compile-time constant in static memory. It also guarantees that there is a 'nul' zero byte at the end, which is not included in the returned range.
Parameters:
- string (
StringSpan[ImmStaticOrigin]): The first StringSpan value. - *extra (
StringSpan[ImmStaticOrigin]): Additional StringSpan values to concatenate.
Returns:
StaticString: The string value as a StaticString.