Map a constant address to its *block* (ingress unit): the `block` address of a projection constant, otherwise the address itself.
(env: &IxonEnv, addr: &Address)
| 1642 | // into the mapping (`LazyConstant::from_mmap_slice`), avoiding the |
| 1643 | // ~3 GB heap copy that `std::fs::read` would impose on mathlib. |
| 1644 | // Sections 3-4 (names + named) are still parse-and-discard, but |
| 1645 | // their decoded forms drop before `get_anon_mmap` returns. |
| 1646 | let t1 = Instant::now(); |
| 1647 | let ixon_env = match IxonEnv::get_anon_mmap(std::path::Path::new(&path)) { |
| 1648 | Ok(env) => env, |
| 1649 | Err(e) => { |
| 1650 | return LeanIOResult::error_string(&format!( |
| 1651 | "rs_kernel_check_anon: failed to mmap+deserialize {path}: {e}" |
| 1652 | )); |
| 1653 | }, |
| 1654 | }; |
| 1655 | eprintln!( |
| 1656 | "[rs_kernel_check_anon] mmap+parse: {:>8.1?} ({} consts; \ |
| 1657 | named={} names={} comms={})", |
| 1658 | t1.elapsed(), |
no test coverage detected