Mica::Core::Position
A place in a format's input, carried by every Mica::ParseError.
byte_offset is 0-based and counts bytes of the original input, before any transcoding (a byte order mark included). line and column are 1-based for text formats (the column counts characters) and 0 for formats without lines.
Mica::Core::Position.new(42_i64, 3, 7).to_s # => "line 3, column 7, byte 42"
Mica::Core::Position.new(42_i64).to_s # => "byte 42"
Constructors
Instance methods
byte_offset
clone
Sourcecolumn
copy_with(byte_offset _byte_offset = @byte_offset, line _line = @line, column _column = @column)
Sourceline