Struct move_binary_format::file_format::CodeUnit
source · pub struct CodeUnit {
pub locals: SignatureIndex,
pub code: Vec<Bytecode>,
}
Expand description
A CodeUnit
is the body of a function. It has the function header and the instruction stream.
Fields§
§locals: SignatureIndex
List of locals type. All locals are typed.
code: Vec<Bytecode>
Code stream, function body.
Trait Implementations§
source§impl Arbitrary for CodeUnit
impl Arbitrary for CodeUnit
§type Parameters = usize
type Parameters = usize
The type of parameters that
arbitrary_with
accepts for configuration
of the generated Strategy
. Parameters must implement Default
.§type Strategy = Map<(<SignatureIndex as Arbitrary>::Strategy, BoxedStrategy<Vec<Bytecode, Global>>), fn(_: (SignatureIndex, Vec<Bytecode, Global>)) -> CodeUnit>
type Strategy = Map<(<SignatureIndex as Arbitrary>::Strategy, BoxedStrategy<Vec<Bytecode, Global>>), fn(_: (SignatureIndex, Vec<Bytecode, Global>)) -> CodeUnit>
The type of
Strategy
used to generate values of type Self
.