build: enable -Winconsistent-missing-override warning

This warning can catch a virtual function that thinks it
overrides another, but doesn't, because the two functions
have different signatures. This isn't very likely since most
of our virtual functions override pure virtuals, but it's
still worth having.

Enable the warning and fix numerous violations.

Closes #9347
This commit is contained in:
Avi Kivity
2021-09-14 20:32:49 +03:00
parent bd8e2e6691
commit daf028210b
49 changed files with 83 additions and 84 deletions

View File

@@ -2061,7 +2061,7 @@ future<db::rp_handle> db::commitlog::add(const cf_id_type& id,
serializer_func_entry_writer(const cf_id_type& id, size_t sz, serializer_func func, db::commitlog::force_sync sync)
: entry_writer(sync), _id(id), _func(std::move(func)), _size(sz)
{}
const cf_id_type& id(size_t) const { return _id; }
const cf_id_type& id(size_t) const override { return _id; }
size_t size(segment&, size_t) override { return _size; }
size_t size(segment&) override { return _size; }
size_t size() const override { return _size; }