fn saturating_u32(v: usize) -> u32Expand description
Convert a usize (line/column/length in the document) into the u32 width
required by the LSP semantic-token wire format. No-op on values below
u32::MAX; saturates otherwise. LSP positions are specified to be u32,
so any document large enough to saturate is already unrepresentable.