Expand description
libspecr
is the standard library of specr lang.
Modules§
- prelude
- The items from this module are automatically imported.
Macros§
- format
- Wrapper around the
std::format
macro returninglibspecr::String
instead ofstd::string::String
. - list
- Construct a
List
.
Structs§
- Align
- This type is basically a copy of the
Align
type in the Rust compiler. See Align. - DynWrite
- Garbage-collected data structure representing a write stream and implementing
Copy
. - Int
- Garbage collected big integer that implements
Copy
and supports construction inconst
contexts. - IntDistribution
- Uniformly samples a random non-negative
Int
… - List
- Garbage-collected
Vec
-like datastructure implementingCopy
. Note that functions which seem to mutate theList
, actually clone the list and allocate a newGcCow
under the hood. - Map
- Garbage-collected hash map implementing
Copy
. - Name
- Wrapper-type for names of any kind.
- NdResult
- Conceptually, this is a
Nondet<Result<T, E>>
. - Nondet
- Non-determinism primitive. See Non-determinism.
- Set
- Garbage-collected hash set implementing
Copy
. - Size
Size
represents a non-negative number of bytes or bits.- String
- Garbage-collected wrapper around
std::string::String
implementingCopy
.
Traits§
- Distribution
- A probability distribution over values of type
T
. - GcWrite
- An object that fulfills both GcCompat and Write.
- Monadic
Return - Satisfied by types that can be constructed from some inner types.
- ToInt
- Conversion to
Int
.
Functions§
- pick
- The
pick
function from the minirust spec. See Non-determinism. - predict
- The
predict
function from the minirust spec. See Non-determinism. - ret
- Wraps a value
i
asSome(i)
,Ok(i)
or something similar of typeT
.