(&self, f: &mut std::fmt::Formatter<'_>)
| 232 | |
| 233 | impl std::fmt::Display for WordDiffOp { |
| 234 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { |
| 235 | match self { |
| 236 | WordDiffOp::Equal { |
| 237 | old_range, |
| 238 | new_range, |
| 239 | } => { |
| 240 | write!(f, "Equal(old:{:?}, new:{:?})", old_range, new_range) |
| 241 | } |
| 242 | WordDiffOp::Insert { old_pos, new_range } => { |
| 243 | write!(f, "Insert(@{}, new:{:?})", old_pos, new_range) |
| 244 | } |
| 245 | WordDiffOp::Delete { old_range, new_pos } => { |
| 246 | write!(f, "Delete(old:{:?}, @{})", old_range, new_pos) |
| 247 | } |
| 248 | WordDiffOp::Replace { |
| 249 | old_range, |
| 250 | new_range, |
| 251 | } => { |
| 252 | write!(f, "Replace(old:{:?}, new:{:?})", old_range, new_range) |
| 253 | } |
| 254 | } |
| 255 | } |
| 256 | } |
| 257 | |
| 258 | /// Result of a word-level diff operation. |
nothing calls this directly
no outgoing calls
no test coverage detected