mirror of
https://github.com/VectorCamp/vectorscan.git
synced 2025-06-28 16:41:01 +03:00
parser: use 'override' keyword in subclasses
This commit is contained in:
parent
46ad39f253
commit
4c53bd4641
@ -57,7 +57,7 @@ public:
|
|||||||
ReferenceVisitor(size_t num_groups, const flat_set<string> &targets)
|
ReferenceVisitor(size_t num_groups, const flat_set<string> &targets)
|
||||||
: num_ids(num_groups), names(targets) {}
|
: num_ids(num_groups), names(targets) {}
|
||||||
|
|
||||||
~ReferenceVisitor();
|
~ReferenceVisitor() override;
|
||||||
|
|
||||||
void invalid_index(const char *component, unsigned id) {
|
void invalid_index(const char *component, unsigned id) {
|
||||||
assert(component);
|
assert(component);
|
||||||
|
@ -201,7 +201,7 @@ const ComponentSequence *findCapturingGroup(const Component *root,
|
|||||||
class PrefilterVisitor : public DefaultComponentVisitor {
|
class PrefilterVisitor : public DefaultComponentVisitor {
|
||||||
public:
|
public:
|
||||||
PrefilterVisitor(Component *c, const ParseMode &m) : root(c), mode(m) {}
|
PrefilterVisitor(Component *c, const ParseMode &m) : root(c), mode(m) {}
|
||||||
~PrefilterVisitor();
|
~PrefilterVisitor() override;
|
||||||
|
|
||||||
/** \brief Calls the visitor (recursively) on a new replacement component
|
/** \brief Calls the visitor (recursively) on a new replacement component
|
||||||
* we've just created. Takes care of freeing it if the sequence is itself
|
* we've just created. Takes care of freeing it if the sequence is itself
|
||||||
|
@ -64,7 +64,7 @@ namespace ue2 {
|
|||||||
*/
|
*/
|
||||||
class ConstructLiteralVisitor : public ConstComponentVisitor {
|
class ConstructLiteralVisitor : public ConstComponentVisitor {
|
||||||
public:
|
public:
|
||||||
~ConstructLiteralVisitor();
|
~ConstructLiteralVisitor() override;
|
||||||
|
|
||||||
/** \brief Thrown if this component does not represent a literal. */
|
/** \brief Thrown if this component does not represent a literal. */
|
||||||
struct NotLiteral {};
|
struct NotLiteral {};
|
||||||
|
@ -44,7 +44,7 @@ namespace ue2 {
|
|||||||
* an unsupported component. */
|
* an unsupported component. */
|
||||||
class UnsupportedVisitor : public DefaultConstComponentVisitor {
|
class UnsupportedVisitor : public DefaultConstComponentVisitor {
|
||||||
public:
|
public:
|
||||||
~UnsupportedVisitor();
|
~UnsupportedVisitor() override;
|
||||||
void pre(const ComponentAssertion &) override {
|
void pre(const ComponentAssertion &) override {
|
||||||
throw ParseError("Zero-width assertions are not supported.");
|
throw ParseError("Zero-width assertions are not supported.");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user