From 1d7ca20f29ff01fff2d4d2f2c8a2e7cbb2291466 Mon Sep 17 00:00:00 2001 From: Zhongyi Xie Date: Thu, 17 May 2018 17:51:46 -0700 Subject: [PATCH] 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 --- db/db_iter_stress_test.cc | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/db/db_iter_stress_test.cc b/db/db_iter_stress_test.cc index f964bbad1..3eb3bb38f 100644 --- a/db/db_iter_stress_test.cc +++ b/db/db_iter_stress_test.cc @@ -173,7 +173,7 @@ struct StressTestIterator : public InternalIterator { } } - void SeekToFirst() { + void SeekToFirst() override { if (MaybeFail()) return; MaybeMutate(); @@ -181,7 +181,7 @@ struct StressTestIterator : public InternalIterator { iter = 0; SkipForward(); } - void SeekToLast() { + void SeekToLast() override { if (MaybeFail()) return; MaybeMutate(); @@ -190,7 +190,7 @@ struct StressTestIterator : public InternalIterator { SkipBackward(); } - void Seek(const Slice& target) { + void Seek(const Slice& target) override { if (MaybeFail()) return; MaybeMutate(); @@ -202,7 +202,7 @@ struct StressTestIterator : public InternalIterator { iter = (int)(it - data->entries.begin()); SkipForward(); } - void SeekForPrev(const Slice& target) { + void SeekForPrev(const Slice& target) override { if (MaybeFail()) return; MaybeMutate(); @@ -216,14 +216,14 @@ struct StressTestIterator : public InternalIterator { SkipBackward(); } - void Next() { + void Next() override { assert(Valid()); if (MaybeFail()) return; MaybeMutate(); ++iter; SkipForward(); } - void Prev() { + void Prev() override { assert(Valid()); if (MaybeFail()) return; MaybeMutate(); @@ -231,11 +231,11 @@ struct StressTestIterator : public InternalIterator { SkipBackward(); } - Slice key() const { + Slice key() const override { assert(Valid()); return data->entries[iter].ikey; } - Slice value() const { + Slice value() const override { assert(Valid()); return data->entries[iter].value; }