7NSTS6PKVQWNUGIUYBRS4GWHJPAV57TOPBTDCOBZ5YYQNFZIZW2QC
RRCSHAYZ6RLWVPNYHF2F5FSRL2KKJNPQUQRIJYLJGB23BZQQ7JLQC
I24UEJQLCH2SOXA4UHIYWTRDCHSOPU7AFTRUOTX7HZIAV4AZKYEQC
SXEYMYF7P4RZMZ46WPL4IZUTSQ2ATBWYZX7QNVMS3SGOYXYOHAGQC
VO5OQW4W2656DIYYRNZ3PO7TQ4JOKQ3GVWE5ALUTYVMX3WMXJOYQC
6YMDOZIB5LVYLFIDGN2WNT5JTHEAMS4TFPVDEZ3OWXWOKJOC5QDAC
CCLLB7OIFNFYJZTG3UCI7536TOCWSCSXR67VELSB466R24WLJSDAC
I52XSRUH5RVHQBFWVMAQPTUSPAJ4KNVID2RMI3UGCVKFLYUO6WZAC
AD6M434OFUCH6ISHP7GXSNNRBHEWP242ZDH7QCVCYLHMRASGE5MQC
YN63NUZO4LVJ7XPMURDULTXBVJKW5MVCTZ24R7Z52QMHO3HPDUVQC
WZVCLZKY34KQBQU6YBGJLQCDADBQ67LQVDNRVCMQVY3O3C3EIWSQC
SFQBWL6PHSX7MQVOSQW4ZO35SLXNHN6562IWYCN4UKWAEVE6AQNQC
let alive = find_alive_down(txn, channel, p)?;
repair_missing_up_context(txn, channel, ws, change_id, inode, dest_vertex, &alive)?;
let alive = find_alive_down(txn, channel, p, &mut ws.alive_down_cache)?;
repair_missing_up_context(
txn,
channel,
ws,
change_id,
inode,
dest_vertex,
&*alive.borrow(),
)?;
) -> Result<HashSet<Vertex<ChangeId>>, BlockError<T::GraphError>> {
let mut stack = vec![(
SerializedEdge::empty(vertex0.start_pos(), ChangeId::ROOT),
0,
)];
cache: &mut HashMap<Vertex<ChangeId>, Alive>,
) -> Result<Alive, BlockError<T::GraphError>> {
let mut stack = vec![SerializedEdge::empty(vertex0.start_pos(), ChangeId::ROOT)];
) -> Result<HashSet<Vertex<ChangeId>>, BlockError<T::GraphError>> {
let mut alive = HashSet::default();
cache: &mut HashMap<Vertex<ChangeId>, (Alive, Alive)>,
) -> Result<Alive, BlockError<T::GraphError>> {
debug!("find alive up: {:?}", vertex0);
let alive = Rc::new(RefCell::new(HashSet::default()));
let files_ = Rc::new(RefCell::new(HashSet::default()));
debug!("vertex = {:?}", vertex);
let is_cached = if let Some((c, f)) = cache.get(&vertex) {
alive.borrow_mut().extend(c.borrow().iter().cloned());
files_.borrow_mut().extend(f.borrow().iter().cloned());
files.extend(f.borrow().iter().cloned());
// We're not continuing here, since the while loop below
// needs to insert stuff into `files` and `files_`.
true
} else {
cache.insert(vertex, (alive.clone(), files_.clone()));
false
};