Add virtual destructors

pull/1032/head
Allofich 8 years ago
parent 51aa613848
commit 8c5aae0722

@ -59,6 +59,8 @@ namespace Compiler
mExprParser (errorHandler, context, locals, literals), mAllowExpression (allowExpression) mExprParser (errorHandler, context, locals, literals), mAllowExpression (allowExpression)
{} {}
LineParser::~LineParser() {}
bool LineParser::parseInt (int value, const TokenLoc& loc, Scanner& scanner) bool LineParser::parseInt (int value, const TokenLoc& loc, Scanner& scanner)
{ {
if (mAllowExpression && mState==BeginState) if (mAllowExpression && mState==BeginState)

@ -51,6 +51,9 @@ namespace Compiler
bool allowExpression = false); bool allowExpression = false);
///< \param allowExpression Allow lines consisting of a naked expression ///< \param allowExpression Allow lines consisting of a naked expression
/// (result is send to the messagebox interface) /// (result is send to the messagebox interface)
virtual ~LineParser();
///< destructor
virtual bool parseInt (int value, const TokenLoc& loc, Scanner& scanner); virtual bool parseInt (int value, const TokenLoc& loc, Scanner& scanner);
///< Handle an int token. ///< Handle an int token.

@ -2,6 +2,8 @@
namespace Misc namespace Misc
{ {
MessageFormatParser::~MessageFormatParser() {}
void MessageFormatParser::process(const std::string& m) void MessageFormatParser::process(const std::string& m)
{ {
for (unsigned int i = 0; i < m.size(); ++i) for (unsigned int i = 0; i < m.size(); ++i)

@ -19,6 +19,8 @@ namespace Misc
virtual void visitedCharacter(char c) = 0; virtual void visitedCharacter(char c) = 0;
public: public:
virtual ~MessageFormatParser();
virtual void process(const std::string& message); virtual void process(const std::string& message);
}; };
} }

Loading…
Cancel
Save