(&self)
| 371 | /// Get the `Id` that will be returned for the next allocation in this slab. |
| 372 | #[inline] |
| 373 | pub fn next_id(&self) -> Id { |
| 374 | let index = self.free.unwrap_or_else(|| EntryIndex::new(self.len())); |
| 375 | Id(index) |
| 376 | } |
| 377 | |
| 378 | #[inline(never)] |
| 379 | #[cold] |