NameSummary
Err Creates a result object representing an error.
Ok Wraps a value in a result object with no error.
array Converts an object to an array.
asciiCode Returns the ASCII code of a single-character string.
bool
echo Prints values to the console.
error Creates a new error object with the given message.
exit
expect
float Converts an object to a float.
hash Returns the hash value of a hashable object.
int Converts an object to an integer.
panic Stops execution and reports an error.
scan Reads a line of input from the user.
string
tuple Creates a new tuple containing the given elements.
type Returns the type of an object as a string.
fn Err(message|error) -> result<T>
Creates a result object representing an error.
Parameters
message|errorA string message or error object.
Returns
fn Ok(value) -> result<T>
Wraps a value in a result object with no error.
Parameters
valueThe value to wrap.
Returns
fn array(object) -> result<array>
Converts an object to an array.
Parameters
objectThe object to convert.
Returns
fn asciiCode(string) -> result<int>
Returns the ASCII code of a single-character string.
Parameters
stringA string containing exactly one character.
Returns
result<int>
fn bool()
fn echo(values) -> null
Prints values to the console.
Parameters
valuesObjects to print.
Returns
null
fn error(message) -> error
Creates a new error object with the given message.
Parameters
messageThe error message string.
Returns
fn exit()
fn expect()
fn float(object) -> result<float>
Converts an object to a float.
Parameters
objectThe object to convert.
Returns
result<float>
fn hash(object) -> result<int>
Returns the hash value of a hashable object.
Parameters
objectThe object to hash.
Returns
result<int>
fn int(object) -> result<int>
Converts an object to an integer.
Parameters
objectThe object to convert.
Returns
result<int>
fn panic(message) -> never
Stops execution and reports an error.
Parameters
messageThe error message string.
Returns
never
fn scan(prompt) -> string
Reads a line of input from the user.
Parameters
promptThe string to display to the user.
Returns
fn string()
fn tuple(elements) -> result<tuple>
Creates a new tuple containing the given elements.
Parameters
elementsObjects to include in the tuple.
Returns
result<tuple>
fn type(object) -> string
Returns the type of an object as a string.
Parameters
objectThe object to inspect.
Returns