oxilean_codegen/opt_licm/loopnest_traits.rs
1//! # LoopNest - Trait Implementations
2//!
3//! This module contains trait implementations for `LoopNest`.
4//!
5//! ## Implemented Traits
6//!
7//! - `Display`
8//!
9//! 🤖 Generated with [SplitRS](https://github.com/cool-japan/splitrs)
10
11use crate::lcnf::*;
12
13use super::types::LoopNest;
14use std::fmt;
15
16impl std::fmt::Display for LoopNest {
17 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
18 let ids: Vec<String> = self.loops.iter().map(|l| l.to_string()).collect();
19 write!(
20 f,
21 "LoopNest({})[perfect={}]",
22 ids.join("->"),
23 self.is_perfect
24 )
25 }
26}