We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b4b4a2f commit 9a1f177Copy full SHA for 9a1f177
compiler/rustc_span/src/lib.rs
@@ -1596,7 +1596,7 @@ macro_rules! impl_pos {
1596
1597
#[inline(always)]
1598
fn add(self, rhs: $ident) -> $ident {
1599
- $ident((self.to_usize() + rhs.to_usize()) as $inner_ty)
+ $ident(self.0 + rhs.0)
1600
}
1601
1602
@@ -1605,7 +1605,7 @@ macro_rules! impl_pos {
1605
1606
1607
fn sub(self, rhs: $ident) -> $ident {
1608
- $ident((self.to_usize() - rhs.to_usize()) as $inner_ty)
+ $ident(self.0 - rhs.0)
1609
1610
1611
)*
0 commit comments