Function
visit
(
name: &Name,
visited: &mut FxHashSet<Address>,
result: &mut Vec<(Address, Name)>,
)
Source from the content-addressed store, hash-verified
| 2102 | name_addr.hex() |
| 2103 | ) |
| 2104 | })?; |
| 2105 | put_u64(name_idx, &mut b); |
| 2106 | let mut scratch = Vec::new(); |
| 2107 | put_named_indexed( |
| 2108 | entry.value(), |
| 2109 | &name_index, |
| 2110 | const_addrs, |
| 2111 | &mut scratch, |
| 2112 | &mut b, |
| 2113 | )?; |
| 2114 | } |
| 2115 | Ok::<_, String>(b) |
| 2116 | }) |
| 2117 | .collect::<Result<_, _>>()?; |
| 2118 | for b in &encoded { |
| 2119 | w.write_all(b).map_err(|e| format!("Env::put_file: write: {e}"))?; |
| 2120 | written += b.len() as u64; |
| 2121 | } |
| 2122 | } |
| 2123 | if verbose { |
| 2124 | eprintln!( |
| 2125 | "[Env::put_file] section 5/6 named done in {:.1}s ({written} bytes \ |
| 2126 | written)", |
| 2127 | sec_start.elapsed().as_secs_f64(), |
Tested by
no test coverage detected