libcamera: bound_method: Mark overriden methods with override

Mark the activate() and invoke() methods with the override keyword where
appropriate.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
This commit is contained in:
Laurent Pinchart
2020-01-04 04:45:25 +02:00
parent 451ffd1fcd
commit 7d66a45b8d

View File

@@ -107,7 +107,7 @@ public:
bool match(void (T::*func)(Args...)) const { return func == func_; }
void activate(Args... args, bool deleteMethod = false)
void activate(Args... args, bool deleteMethod = false) override
{
if (this->object_)
BoundMethodBase::activatePack(new PackType{ args... }, deleteMethod);
@@ -115,7 +115,7 @@ public:
(static_cast<T *>(this->obj_)->*func_)(args...);
}
void invoke(Args... args)
void invoke(Args... args) override
{
(static_cast<T *>(this->obj_)->*func_)(args...);
}
@@ -136,12 +136,12 @@ public:
bool match(void (*func)(Args...)) const { return func == func_; }
void activate(Args... args, bool deleteMethod = false)
void activate(Args... args, bool deleteMethod = false) override
{
(*func_)(args...);
}
void invoke(Args...) {}
void invoke(Args...) override {}
private:
void (*func_)(Args...);