Skip to content

Commit c6f71fd

Browse files
committed
Refactor (Tokenizer): Add member functions: tell, size, remaining
1 parent af5774b commit c6f71fd

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

libraries/libim/text/tokenizer.h

+14
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,20 @@ namespace libim::text {
6969
bool reportEol() const;
7070

7171
const InputStream& istream() const;
72+
std::size_t size() const
73+
{
74+
return istream().size();
75+
}
76+
77+
std::size_t tell() const
78+
{
79+
return istream().tell();
80+
}
81+
82+
std::size_t remaining() const
83+
{
84+
return istream().remaining();
85+
}
7286

7387
protected:
7488
void getNextToken(Token& out);

0 commit comments

Comments
 (0)