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

Method merge

atomic-agent/src/event.rs:554–563  ·  view source on GitHub ↗

Merge another `TurnChanges` into this one. Used when combining sub-turn changes (e.g., from multiple tool invocations within a single turn). Deduplicates paths.

(&mut self, other: &TurnChanges)

Source from the content-addressed store, hash-verified

552 /// Used when combining sub-turn changes (e.g., from multiple tool
553 /// invocations within a single turn). Deduplicates paths.
554 pub fn merge(&mut self, other: &TurnChanges) {
555 merge_paths(&mut self.modified, &other.modified);
556 merge_paths(&mut self.added, &other.added);
557 merge_paths(&mut self.deleted, &other.deleted);
558
559 // Use the later timestamp
560 if other.timestamp > self.timestamp {
561 self.timestamp = other.timestamp;
562 }
563 }
564
565 /// Returns a summary string suitable for log messages.
566 ///

Calls 1

merge_pathsFunction · 0.85