add override to virtual functions

Summary:
this will fix the failing clang_check test
Closes https://github.com/facebook/rocksdb/pull/3868

Differential Revision: D8050880

Pulled By: miasantreble

fbshipit-source-id: 749932e2e4025f835c961c068d601e522a126da6
main
Zhongyi Xie 7 years ago committed by Facebook Github Bot
parent aed7abbcca
commit 1d7ca20f29
  1. 16
      db/db_iter_stress_test.cc

@ -173,7 +173,7 @@ struct StressTestIterator : public InternalIterator {
} }
} }
void SeekToFirst() { void SeekToFirst() override {
if (MaybeFail()) return; if (MaybeFail()) return;
MaybeMutate(); MaybeMutate();
@ -181,7 +181,7 @@ struct StressTestIterator : public InternalIterator {
iter = 0; iter = 0;
SkipForward(); SkipForward();
} }
void SeekToLast() { void SeekToLast() override {
if (MaybeFail()) return; if (MaybeFail()) return;
MaybeMutate(); MaybeMutate();
@ -190,7 +190,7 @@ struct StressTestIterator : public InternalIterator {
SkipBackward(); SkipBackward();
} }
void Seek(const Slice& target) { void Seek(const Slice& target) override {
if (MaybeFail()) return; if (MaybeFail()) return;
MaybeMutate(); MaybeMutate();
@ -202,7 +202,7 @@ struct StressTestIterator : public InternalIterator {
iter = (int)(it - data->entries.begin()); iter = (int)(it - data->entries.begin());
SkipForward(); SkipForward();
} }
void SeekForPrev(const Slice& target) { void SeekForPrev(const Slice& target) override {
if (MaybeFail()) return; if (MaybeFail()) return;
MaybeMutate(); MaybeMutate();
@ -216,14 +216,14 @@ struct StressTestIterator : public InternalIterator {
SkipBackward(); SkipBackward();
} }
void Next() { void Next() override {
assert(Valid()); assert(Valid());
if (MaybeFail()) return; if (MaybeFail()) return;
MaybeMutate(); MaybeMutate();
++iter; ++iter;
SkipForward(); SkipForward();
} }
void Prev() { void Prev() override {
assert(Valid()); assert(Valid());
if (MaybeFail()) return; if (MaybeFail()) return;
MaybeMutate(); MaybeMutate();
@ -231,11 +231,11 @@ struct StressTestIterator : public InternalIterator {
SkipBackward(); SkipBackward();
} }
Slice key() const { Slice key() const override {
assert(Valid()); assert(Valid());
return data->entries[iter].ikey; return data->entries[iter].ikey;
} }
Slice value() const { Slice value() const override {
assert(Valid()); assert(Valid());
return data->entries[iter].value; return data->entries[iter].value;
} }

Loading…
Cancel
Save