Create a new conflict writer. # Arguments `writer` - The underlying writer to wrap `path` - Path to the file being written (for conflict reporting) `position` - The graph position of this file's inode # Example ```rust use atomic_core::output::repo::ConflictWriter; use atomic_core::types::{NodeId, Position, ChangePosition}; let mut buffer = Vec::new(); let pos = Position::new(NodeId::new(1),
(writer: W, path: &str, position: Position<NodeId>)
| 174 | /// assert!(writer.conflicts().is_empty()); |
| 175 | /// ``` |
| 176 | pub fn new(writer: W, path: &str, position: Position<NodeId>) -> Self { |
| 177 | Self { |
| 178 | writer, |
| 179 | path: path.to_string(), |
| 180 | position, |
| 181 | conflicts: Vec::new(), |
| 182 | line: 1, |
| 183 | next_conflict_id: 1, |
| 184 | at_line_start: true, |
| 185 | bytes_written: 0, |
| 186 | content_buffer: Vec::with_capacity(4096), |
| 187 | } |
| 188 | } |
| 189 | |
| 190 | /// Get the path of the file being written. |
| 191 | pub fn path(&self) -> &str { |
nothing calls this directly
no outgoing calls
no test coverage detected