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

Method fmt

atomic-core/src/change/ops.rs:534–553  ·  view source on GitHub ↗
(&self, f: &mut fmt::Formatter<'_>)

Source from the content-addressed store, hash-verified

532
533impl fmt::Display for FileOps {
534 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
535 let op_type = match &self.trunk_op {
536 Some(TrunkOp::Create { .. }) => "create",
537 Some(TrunkOp::Delete { .. }) => "delete",
538 Some(TrunkOp::Move { .. }) => "move",
539 Some(TrunkOp::Undelete { .. }) => "undelete",
540 Some(TrunkOp::SetMode { .. }) => "set-mode",
541 Some(TrunkOp::SetKind { .. }) => "set-kind",
542 Some(TrunkOp::ProjectedSpanEdit { .. }) => "projected-span-edit",
543 None => "edit",
544 };
545 write!(
546 f,
547 "FileOps({} {}, {} lines, {} tokens)",
548 op_type,
549 self.path,
550 self.line_ops.len(),
551 self.token_count()
552 )
553 }
554}
555
556// LineOps (Branch Level)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected