xo-tokenizer: minor streamlining

This commit is contained in:
Roland Conybeare 2025-06-25 07:51:01 -05:00
commit f9e52987bf

View file

@ -49,16 +49,16 @@ namespace xo {
/** capture prefix of @p input up to first newline **/ /** capture prefix of @p input up to first newline **/
void capture_current_line(const span_type & input); void capture_current_line(const span_type & input);
/** reset input state for start of next line **/ /** Reset input state for start of next line.
* Expression parser may use this to discard remainder of input line
* after a parsing error.
**/
void discard_current_line(); void discard_current_line();
void consume(size_t z) { current_pos_ += z; } void consume(size_t z) { current_pos_ += z; }
const CharT * skip_leading_whitespace(const span_type & input); const CharT * skip_leading_whitespace(const span_type & input);
private:
//void reset_whitespace() { whitespace_ = 0; }
private: private:
/** remember current input line. Used only to report errors **/ /** remember current input line. Used only to report errors **/
span<const CharT> current_line_ = span<const CharT>(); span<const CharT> current_line_ = span<const CharT>();