mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-12-25 03:04:13 +03:00
Merge pull request #1971 from AleoHQ/doc-span-add
[span] Add doc comment to explain span addition.
This commit is contained in:
commit
0cd6a10d6f
@ -71,6 +71,8 @@ impl std::ops::Add for &Span {
|
||||
impl std::ops::Add for Span {
|
||||
type Output = Self;
|
||||
|
||||
/// Add two spans together.
|
||||
/// The resulting span is the smallest span that includes both.
|
||||
fn add(self, other: Self) -> Self {
|
||||
let lo = self.lo.min(other.lo);
|
||||
let hi = self.hi.max(other.hi);
|
||||
|
Loading…
Reference in New Issue
Block a user