Skip to content

Commit

Permalink
Add error message when not finding the ICH of a DepNode.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelwoerister committed Nov 18, 2016
1 parent 195c42c commit 003b169
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/librustc_incremental/calculate_svh/mod.rs
Expand Up @@ -88,7 +88,12 @@ impl<'a> ::std::ops::Index<&'a DepNode<DefId>> for IncrementalHashesMap {
type Output = Fingerprint;

fn index(&self, index: &'a DepNode<DefId>) -> &Fingerprint {
&self.hashes[index]
match self.hashes.get(index) {
Some(fingerprint) => fingerprint,
None => {
bug!("Could not find ICH for {:?}", index);
}
}
}
}

Expand Down

0 comments on commit 003b169

Please sign in to comment.