diff --git a/src/Lexer.cpp b/src/Lexer.cpp index 6d42fdac..a33b48f8 100644 --- a/src/Lexer.cpp +++ b/src/Lexer.cpp @@ -34,7 +34,6 @@ //////////////////////////////////////////////////////////////////////////////// Lexer::Lexer (const std::string& text) : _text (text) -, _cursor (0) , _eos (text.size ()) { } diff --git a/src/Lexer.h b/src/Lexer.h index a14d79d2..2dcbff2b 100644 --- a/src/Lexer.h +++ b/src/Lexer.h @@ -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