diff options
Diffstat (limited to 'lib/vnf')
| -rw-r--r-- | lib/vnf/Cargo.toml | 1 | ||||
| -rw-r--r-- | lib/vnf/src/lib.rs | 3 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/vnf/Cargo.toml b/lib/vnf/Cargo.toml index 66bed81..e119a27 100644 --- a/lib/vnf/Cargo.toml +++ b/lib/vnf/Cargo.toml @@ -8,3 +8,4 @@ authors.workspace = true [dependencies] header.workspace = true xixanta.workspace = true +rand = "0.10" diff --git a/lib/vnf/src/lib.rs b/lib/vnf/src/lib.rs index dc314bd..7fbe264 100644 --- a/lib/vnf/src/lib.rs +++ b/lib/vnf/src/lib.rs @@ -307,7 +307,7 @@ fn init_memory(policy: &MemoryPolicy) -> Vec<MemoryCell> { vec.push(MemoryCell { value: match policy.initial_value { MemoryInitialValue::Fixed(n) => n, - MemoryInitialValue::Random => todo!(), + MemoryInitialValue::Random => rand::random(), }, write_allowed, read_allowed, @@ -369,7 +369,6 @@ impl Machine { } } - // TODO: allow for randomized initialization. Ok(Self { active: true, run_function_mode: false, |
