diff options
author | 2017-05-26 18:26:46 -0700 | |
---|---|---|
committer | 2017-05-26 20:45:56 -0700 | |
commit | cfbc9d26d6f75ba70ac1e566774b2b2d487bef6e (patch) | |
tree | f6b2c60034c62f437d8f8c71b94e92c9c1e467ed /tensorflow/core/lib/io/block.cc | |
parent | 49b17146d2e4f04192d16ed67574142de167f3a1 (diff) |
Annotate overriding functions with "override" or "final" (and not with "virtual")
PiperOrigin-RevId: 157284709
Diffstat (limited to 'tensorflow/core/lib/io/block.cc')
-rw-r--r-- | tensorflow/core/lib/io/block.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tensorflow/core/lib/io/block.cc b/tensorflow/core/lib/io/block.cc index 6dd6a9ce6f..30c842208f 100644 --- a/tensorflow/core/lib/io/block.cc +++ b/tensorflow/core/lib/io/block.cc @@ -130,23 +130,23 @@ class Block::Iter : public Iterator { assert(num_restarts_ > 0); } - virtual bool Valid() const { return current_ < restarts_; } - virtual Status status() const { return status_; } - virtual StringPiece key() const { + bool Valid() const override { return current_ < restarts_; } + Status status() const override { return status_; } + StringPiece key() const override { assert(Valid()); return key_; } - virtual StringPiece value() const { + StringPiece value() const override { assert(Valid()); return value_; } - virtual void Next() { + void Next() override { assert(Valid()); ParseNextKey(); } - virtual void Seek(const StringPiece& target) { + void Seek(const StringPiece& target) override { // Binary search in restart array to find the last restart point // with a key < target uint32 left = 0; @@ -186,7 +186,7 @@ class Block::Iter : public Iterator { } } - virtual void SeekToFirst() { + void SeekToFirst() override { SeekToRestartPoint(0); ParseNextKey(); } |