You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Method SourceFile::normalized_byte_pos is broken #149568
Here offset is a byte offset relative to the start of the file. The problem is, that NormalizedPos contains a relative byte pos, but we are comparing it with an absolute one. The current definition of NormalizedPos is the following:
pubstructNormalizedPos{/// The relative offset of the character in the `SourceFile`.pubpos:RelativeBytePos,/// The difference between original and normalized string at position.pubdiff:u32,}
When the method normalized_byte_pos was introduced(bba2a1e) the NormalizedPos used an absolute byte pos. But it was later to changed to use relative byte pos in 258ace6
Activity
eggyal commentedon Jan 21, 2026
@rustbot claim
Rollup merge of rust-lang#151455 - eggyal:normalized-byte-pos, r=cjgi…
Rollup merge of rust-lang#151455 - eggyal:normalized-byte-pos, r=cjgi…
Rollup merge of rust-lang#151455 - eggyal:normalized-byte-pos, r=cjgi…
Rollup merge of rust-lang#151455 - eggyal:normalized-byte-pos, r=cjgi…
Auto merge of #151455 - eggyal:normalized-byte-pos, r=cjgillot
Rollup merge of rust-lang#151455 - eggyal:normalized-byte-pos, r=cjgi…
Unrolled build for #151455