| Message ID | 20251208110035.248881-1-barnabas.pocze@ideasonboard.com |
|---|---|
| State | Deferred |
| Headers | show |
| Series |
|
| Related | show |
Hi Barnabás On Mon, Dec 08, 2025 at 12:00:33PM +0100, Barnabás Pőcze wrote: > Mark the overridden virtual functions as "override". > > Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com> > --- > include/libcamera/internal/device_enumerator_udev.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/include/libcamera/internal/device_enumerator_udev.h b/include/libcamera/internal/device_enumerator_udev.h > index 1378c1906d..fb0005921a 100644 > --- a/include/libcamera/internal/device_enumerator_udev.h > +++ b/include/libcamera/internal/device_enumerator_udev.h Does device_enumerator_sysfs.h deserve the same ? > @@ -32,8 +32,8 @@ public: > DeviceEnumeratorUdev(); > ~DeviceEnumeratorUdev(); > > - int init(); > - int enumerate(); > + int init() override; > + int enumerate() override; > > private: > using DependencyMap = std::map<dev_t, std::list<MediaEntity *>>; > -- > 2.52.0 >
2025. 12. 11. 12:58 keltezéssel, Jacopo Mondi írta: > Hi Barnabás > > On Mon, Dec 08, 2025 at 12:00:33PM +0100, Barnabás Pőcze wrote: >> Mark the overridden virtual functions as "override". >> >> Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com> >> --- >> include/libcamera/internal/device_enumerator_udev.h | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) >> >> diff --git a/include/libcamera/internal/device_enumerator_udev.h b/include/libcamera/internal/device_enumerator_udev.h >> index 1378c1906d..fb0005921a 100644 >> --- a/include/libcamera/internal/device_enumerator_udev.h >> +++ b/include/libcamera/internal/device_enumerator_udev.h > > Does device_enumerator_sysfs.h deserve the same ? Yes But maybe I should drop this change and wait until clang-tidy is enabled and does the `modernize-use-override` check, which would warn about these cases. > >> @@ -32,8 +32,8 @@ public: >> DeviceEnumeratorUdev(); >> ~DeviceEnumeratorUdev(); >> >> - int init(); >> - int enumerate(); >> + int init() override; >> + int enumerate() override; >> >> private: >> using DependencyMap = std::map<dev_t, std::list<MediaEntity *>>; >> -- >> 2.52.0 >>
diff --git a/include/libcamera/internal/device_enumerator_udev.h b/include/libcamera/internal/device_enumerator_udev.h index 1378c1906d..fb0005921a 100644 --- a/include/libcamera/internal/device_enumerator_udev.h +++ b/include/libcamera/internal/device_enumerator_udev.h @@ -32,8 +32,8 @@ public: DeviceEnumeratorUdev(); ~DeviceEnumeratorUdev(); - int init(); - int enumerate(); + int init() override; + int enumerate() override; private: using DependencyMap = std::map<dev_t, std::list<MediaEntity *>>;
Mark the overridden virtual functions as "override". Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com> --- include/libcamera/internal/device_enumerator_udev.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)