Skip to content

std.collections

Generated by sema doc from stdlib/sema/collections.sema. Import with from std.collections import …. For a narrative introduction see std.collections.

std.collections — small pure helpers used across the standard library.

Part of the Sema standard library, written in Sema and shipped with the compiler (embedded via crates/sema-runtime/src/stdlib.rs). Import with from std.collections import join_str, r6, ....

def r6(x: f64) -> f64 !{}

Parameters

nametype
xf64

Returns f64

Effects !{}

def join_str(xs: list[str], sep: str) -> str !{}

Parameters

nametype
xslist[str]
sepstr

Returns str

Effects !{}

def join_ints(xs: list[int], sep: str) -> str !{}

Parameters

nametype
xslist[int]
sepstr

Returns str

Effects !{}

def join_floats(xs: list[f64], sep: str) -> str !{}

Parameters

nametype
xslist[f64]
sepstr

Returns str

Effects !{}

def dedup_ints(xs: list[int]) -> list[int] !{}

Parameters

nametype
xslist[int]

Returns list[int]

Effects !{}