Skip to main content

Mojo function

env_get_string

env_get_string[name: StringSlice[StaticConstantOrigin]]() -> StaticString

Try to get a string-valued define. Compilation fails if the name is not defined.

Deprecated: use get_defined_string from sys.defines instead

Parameters:

Returns:

StaticString: A string parameter value.

env_get_string[name: StringSlice[StaticConstantOrigin], default: StringSlice[StaticConstantOrigin]]() -> StaticString

Try to get a string-valued define. If the name is not defined, return a default value instead.

Deprecated: use get_defined_string from sys.defines instead

Parameters:

Returns:

StaticString: A string parameter value.

Was this page helpful?