Std.Text.Source
9 public declarations
- byteLength
&Std.Text.Source.Source -> IntHow many bytes the text occupies.
- fromBytes
&Bytes -> Std.Text.Source.SourceIndex LF delimiters without decoding or copying the source bytes.
- fromText
Str -> Std.Text.Source.SourceEncode UTF-8 explicitly before building the byte-coordinate index.
- line
&Std.Text.Source.Source -> Int -> Option[Bytes]Return a line without its LF or CRLF delimiter, preserving standalone CR.
- lineCount
&Std.Text.Source.Source -> IntHow many lines the text has.
- position
&Std.Text.Source.Source -> Int -> Option[Std.Text.Source.Position]Locate an absolute byte offset. A byte inside UTF-8 still has a byte column.
- Position
One-based line and byte column; offset is zero-based and may name EOF.
- slice
&Std.Text.Source.Source -> Int -> Int -> Option[Bytes]Return an exact half-open byte range; invalid bounds never clamp silently.
- Source
Byte storage and ascending line starts, built together by the constructors.
