From: Justin Viiret Date: Tue, 3 Nov 2015 05:11:56 +0000 (+1100) Subject: parser: use 'override' keyword in subclasses X-Git-Tag: v4.1.0^2~35 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4c53bd46413cd54f0c85863addf675edfca88f9b;p=thirdparty%2Fvectorscan.git parser: use 'override' keyword in subclasses --- diff --git a/src/parser/check_refs.cpp b/src/parser/check_refs.cpp index 6307a06a..ad81ae76 100644 --- a/src/parser/check_refs.cpp +++ b/src/parser/check_refs.cpp @@ -57,7 +57,7 @@ public: ReferenceVisitor(size_t num_groups, const flat_set &targets) : num_ids(num_groups), names(targets) {} - ~ReferenceVisitor(); + ~ReferenceVisitor() override; void invalid_index(const char *component, unsigned id) { assert(component); diff --git a/src/parser/prefilter.cpp b/src/parser/prefilter.cpp index de99d9f1..f5a0c66c 100644 --- a/src/parser/prefilter.cpp +++ b/src/parser/prefilter.cpp @@ -201,7 +201,7 @@ const ComponentSequence *findCapturingGroup(const Component *root, class PrefilterVisitor : public DefaultComponentVisitor { public: PrefilterVisitor(Component *c, const ParseMode &m) : root(c), mode(m) {} - ~PrefilterVisitor(); + ~PrefilterVisitor() override; /** \brief Calls the visitor (recursively) on a new replacement component * we've just created. Takes care of freeing it if the sequence is itself diff --git a/src/parser/shortcut_literal.cpp b/src/parser/shortcut_literal.cpp index d2b77dc5..f6f5d383 100644 --- a/src/parser/shortcut_literal.cpp +++ b/src/parser/shortcut_literal.cpp @@ -64,7 +64,7 @@ namespace ue2 { */ class ConstructLiteralVisitor : public ConstComponentVisitor { public: - ~ConstructLiteralVisitor(); + ~ConstructLiteralVisitor() override; /** \brief Thrown if this component does not represent a literal. */ struct NotLiteral {}; diff --git a/src/parser/unsupported.cpp b/src/parser/unsupported.cpp index b0b15d8d..c97a5750 100644 --- a/src/parser/unsupported.cpp +++ b/src/parser/unsupported.cpp @@ -44,7 +44,7 @@ namespace ue2 { * an unsupported component. */ class UnsupportedVisitor : public DefaultConstComponentVisitor { public: - ~UnsupportedVisitor(); + ~UnsupportedVisitor() override; void pre(const ComponentAssertion &) override { throw ParseError("Zero-width assertions are not supported."); }