Skip to content

Commit 0ba7d41

Browse files
committed
Auto merge of #58458 - nnethercote:tweak-Span-encoding, r=petrochenkov
Tweak `Span` encoding. Failing to fit `base` is more common than failing to fit `len`.
2 parents 546cb21 + ff94fea commit 0ba7d41

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/libsyntax_pos/span_encoding.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -74,12 +74,12 @@ const CTXT_INDEX: usize = 2;
7474

7575
// Tag = 0, inline format.
7676
// -------------------------------------------------------------
77-
// | base 31:8 | len 7:1 | ctxt (currently 0 bits) | tag 0:0 |
77+
// | base 31:7 | len 6:1 | ctxt (currently 0 bits) | tag 0:0 |
7878
// -------------------------------------------------------------
7979
// Since there are zero bits for ctxt, only SpanData with a 0 SyntaxContext
8080
// can be inline.
81-
const INLINE_SIZES: [u32; 3] = [24, 7, 0];
82-
const INLINE_OFFSETS: [u32; 3] = [8, 1, 1];
81+
const INLINE_SIZES: [u32; 3] = [25, 6, 0];
82+
const INLINE_OFFSETS: [u32; 3] = [7, 1, 1];
8383

8484
// Tag = 1, interned format.
8585
// ------------------------

0 commit comments

Comments
 (0)