The context vertex at `pos`: one written earlier in this change, else the inode-scoped lookup (`is_predecessor` selects the end-of-span or start-of-span reading of `pos`).
(
txn: &CachedWriteGraphTxn<'_, '_>,
workspace: &Workspace,
inode: Option<Inode>,
pos: Position<NodeId>,
is_predecessor: bool,
)
| 310 | /// the inode-scoped lookup (`is_predecessor` selects the end-of-span or |
| 311 | /// start-of-span reading of `pos`). |
| 312 | fn context_vertex( |
| 313 | txn: &CachedWriteGraphTxn<'_, '_>, |
| 314 | workspace: &Workspace, |
| 315 | inode: Option<Inode>, |
| 316 | pos: Position<NodeId>, |
| 317 | is_predecessor: bool, |
| 318 | ) -> Result<GraphNode<NodeId>, LocalApplyError> { |
| 319 | match workspace.get_current_vertex(pos, is_predecessor) { |
| 320 | Some(vertex) => Ok(vertex), |
| 321 | None => resolve_context_vertex_in_inode(txn, inode, pos, is_predecessor), |
| 322 | } |
| 323 | } |
| 324 | |
| 325 | /// Resolve a context position through the file's own vertex index first. |
| 326 | /// |
no test coverage detected