(helper: &mut MyHelper, id: String, v: IDLValue, is_call: bool, display: bool)
| 240 | } |
| 241 | |
| 242 | fn bind_value(helper: &mut MyHelper, id: String, v: IDLValue, is_call: bool, display: bool) { |
| 243 | if display { |
| 244 | if helper.verbose { |
| 245 | println!("{v}"); |
| 246 | } else if let IDLValue::Text(v) = &v { |
| 247 | println!("{v}"); |
| 248 | } |
| 249 | } |
| 250 | if is_call { |
| 251 | let (v, cost) = crate::profiling::may_extract_profiling(v); |
| 252 | if let Some(cost) = cost { |
| 253 | let cost_id = format!("__cost_{id}"); |
| 254 | helper.env.0.insert(cost_id, IDLValue::Int64(cost)); |
| 255 | } |
| 256 | helper.env.0.insert(id, v); |
| 257 | } else { |
| 258 | helper.env.0.insert(id, v); |
| 259 | } |
| 260 | } |
no test coverage detected