Fix bug in to_full_offset when Anchor::version != Content::version

This commit is contained in:
Antonio Scandurra 2021-10-27 11:56:04 +02:00
parent c539069cbb
commit a7a73a5b0b
2 changed files with 92 additions and 8 deletions

View file

@ -2496,10 +2496,6 @@ impl ToOffset for Anchor {
fn to_offset<'a>(&self, content: impl Into<Content<'a>>) -> usize {
content.into().summary_for_anchor(self).bytes
}
fn to_full_offset<'a>(&self, _: impl Into<Content<'a>>, _: Bias) -> usize {
self.full_offset
}
}
impl<'a> ToOffset for &'a Anchor {