Skip to content

Commit

Permalink
kv: silence the gcc warning of func foo was hidden
Browse files Browse the repository at this point in the history
this silences the warnings like

ceph/ceph/src/kv/KeyValueDB.h:59:18: warning: ‘virtual void
KeyValueDB::TransactionImpl::set(const string&, const char*, size_t,
const bufferlist&)’ was hidden [-Woverloaded-\
virtual]
     virtual void set(
                  ^~~

Signed-off-by: Kefu Chai <kchai@redhat.com>
  • Loading branch information
tchaikov committed Feb 16, 2017
1 parent 138fdcb commit 5536617
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/kv/LevelDBStore.h
Expand Up @@ -190,12 +190,14 @@ class LevelDBStore : public KeyValueDB {
const string &prefix,
const string &k,
const bufferlist &bl);
using KeyValueDB::TransactionImpl::set;
void rmkey(
const string &prefix,
const string &k);
void rmkeys_by_prefix(
const string &prefix
);
using KeyValueDB::TransactionImpl::rmkey;
};

KeyValueDB::Transaction get_transaction() {
Expand All @@ -213,7 +215,9 @@ class LevelDBStore : public KeyValueDB {
int get(const string &prefix,
const string &key,
bufferlist *value);


using KeyValueDB::get;

class LevelDBWholeSpaceIteratorImpl :
public KeyValueDB::WholeSpaceIteratorImpl {
protected:
Expand Down
6 changes: 5 additions & 1 deletion src/kv/MemDB.h
Expand Up @@ -86,7 +86,9 @@ class MemDB : public KeyValueDB

void set(const std::string &prefix, const std::string &key,
const bufferlist &val);
using KeyValueDB::TransactionImpl::set;
void rmkey(const std::string &prefix, const std::string &k);
using KeyValueDB::TransactionImpl::rmkey;
void rmkeys_by_prefix(const std::string &prefix);

void merge(const std::string &prefix, const std::string &key, const bufferlist &value);
Expand Down Expand Up @@ -127,11 +129,13 @@ class MemDB : public KeyValueDB
int submit_transaction_sync(Transaction);

int get(const std::string &prefix, const std::set<std::string> &key,
std::map<std::string, bufferlist> *out);
std::map<std::string, bufferlist> *out) override;

int get(const std::string &prefix, const std::string &key,
bufferlist *out) override;

using KeyValueDB::get;

class MDBWholeSpaceIteratorImpl : public KeyValueDB::WholeSpaceIteratorImpl {

mdb_iter_t m_iter;
Expand Down

0 comments on commit 5536617

Please sign in to comment.