Checks if the given [Span] would fit entirely within this [Span].
(&self, span: Span)
| 48 | |
| 49 | /// Checks if the given [Span] would fit entirely within this [Span]. |
| 50 | pub fn contains(&self, span: Span) -> bool { |
| 51 | self.start <= span.start && span.end <= self.end |
| 52 | } |
| 53 | |
| 54 | /// Checks if this [Span] overlaps with the given [Span] (i.e. they share at least one byte). |
| 55 | pub fn overlaps(&self, span: Span) -> bool { |
no outgoing calls