#pragma once #include namespace lexer { // controlled character stream access class Cursor { private: const std::string &source; int position; // current index in string int line; // current index of line int column; // public: char current(); // returns current symbol char peek(int offset); // void advance(); bool eol() const; bool eof() const; }; }