Commit c1f9a01
committed
add naive default impl for GuestMemory::num_regions
Similar to find_region(), we can provide an inefficient default impl to
make downstream impls of the trait less verbose in scenarios that really
do not care (e.g. mock impls for tests).
Signed-off-by: Patrick Roy <roypat@amazon.co.uk>1 parent 15606ea commit c1f9a01
2 files changed
+5
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | | - | |
| 13 | + | |
| 14 | + | |
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
405 | 405 | | |
406 | 406 | | |
407 | 407 | | |
408 | | - | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
409 | 411 | | |
410 | 412 | | |
411 | 413 | | |
| |||
0 commit comments