This commit is contained in:
Nathan Sobo 2021-12-10 22:16:39 -07:00
parent 8432daef6a
commit f5c775fcd1
2 changed files with 44 additions and 29 deletions

View file

@ -777,7 +777,7 @@ impl MultiBufferSnapshot {
summary
}
fn summary_for_anchor<D>(&self, anchor: &Anchor) -> D
pub fn summary_for_anchor<D>(&self, anchor: &Anchor) -> D
where
D: TextDimension + Ord + Sub<D, Output = D>,
{
@ -798,7 +798,7 @@ impl MultiBufferSnapshot {
D::from_text_summary(&cursor.start().text)
}
fn summaries_for_anchors<'a, D, I>(&'a self, anchors: I) -> Vec<D>
pub fn summaries_for_anchors<'a, D, I>(&'a self, anchors: I) -> Vec<D>
where
D: TextDimension + Ord + Sub<D, Output = D>,
I: 'a + IntoIterator<Item = &'a Anchor>,