MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / deletions

Method deletions

atomic-core/src/diff/ops.rs:200–207  ·  view source on GitHub ↗

Get the number of lines deleted by this operation.

(&self)

Source from the content-addressed store, hash-verified

198
199 /// Get the number of lines deleted by this operation.
200 pub fn deletions(&self) -> usize {
201 match *self {
202 DiffOp::Equal { .. } => 0,
203 DiffOp::Insert { .. } => 0,
204 DiffOp::Delete { len, .. } => len,
205 DiffOp::Replace { old_len, .. } => old_len,
206 }
207 }
208
209 /// Get the number of lines inserted by this operation.
210 pub fn insertions(&self) -> usize {

Callers 1

edit_distanceMethod · 0.45

Calls 1

iterMethod · 0.45

Tested by

no test coverage detected