Skip to main content

oxilean_runtime/arena/
generationalarena_traits.rs

1//! # GenerationalArena - Trait Implementations
2//!
3//! This module contains trait implementations for `GenerationalArena`.
4//!
5//! ## Implemented Traits
6//!
7//! - `Default`
8//! - `Debug`
9//!
10//! 🤖 Generated with [SplitRS](https://github.com/cool-japan/splitrs)
11
12use super::types::GenerationalArena;
13use std::fmt;
14
15impl<T> Default for GenerationalArena<T> {
16    fn default() -> Self {
17        Self::new()
18    }
19}
20
21impl<T: fmt::Debug> fmt::Debug for GenerationalArena<T> {
22    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
23        f.debug_struct("GenerationalArena")
24            .field("len", &self.len())
25            .field("capacity", &self.entries.len())
26            .field("generation", &self.generation)
27            .finish()
28    }
29}