oxilean_codegen/opt_cse/
cseconfig_traits.rs1use crate::lcnf::*;
13
14use super::types::CseConfig;
15use std::fmt;
16
17impl Default for CseConfig {
18 fn default() -> Self {
19 CseConfig {
20 max_expr_size: 20,
21 track_calls: false,
22 max_candidates: 1000,
23 pure_functions: vec![],
24 }
25 }
26}
27
28impl fmt::Display for CseConfig {
29 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
30 write!(
31 f,
32 "CseConfig {{ max_expr_size={}, track_calls={}, max_candidates={} }}",
33 self.max_expr_size, self.track_calls, self.max_candidates
34 )
35 }
36}