mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-07-07 20:06:39 +02:00
Lexer: Improved CppCoreGuidelines compliance
This commit is contained in:
parent
672666593b
commit
3b402e5f49
2 changed files with 4 additions and 5 deletions
|
@ -34,7 +34,6 @@
|
|||
////////////////////////////////////////////////////////////////////////////////
|
||||
Lexer::Lexer (const std::string& text)
|
||||
: _text (text)
|
||||
, _cursor (0)
|
||||
, _eos (text.size ())
|
||||
{
|
||||
}
|
||||
|
|
|
@ -43,7 +43,7 @@ public:
|
|||
op,
|
||||
word };
|
||||
|
||||
Lexer (const std::string&);
|
||||
explicit Lexer (const std::string&);
|
||||
bool token (std::string&, Lexer::Type&);
|
||||
static std::string typeToString (Lexer::Type);
|
||||
|
||||
|
@ -78,9 +78,9 @@ public:
|
|||
bool isWord (std::string&, Lexer::Type&);
|
||||
|
||||
private:
|
||||
std::string _text;
|
||||
std::size_t _cursor;
|
||||
std::size_t _eos;
|
||||
std::string _text {};
|
||||
std::size_t _cursor {0};
|
||||
std::size_t _eos {0};
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue