diff options
author | 2018-06-25 13:52:55 -0700 | |
---|---|---|
committer | 2018-06-25 13:52:55 -0700 | |
commit | 0b0890b36d01bf7b372cb237998ee793f5cdc433 (patch) | |
tree | 20f4e0b1ad1f74f794f2cb45110841f2b26af23b /src/google/protobuf/util/message_differencer.h | |
parent | d9ccd0c0e6bbda9bf4476088eeb46b02d7dcd327 (diff) | |
parent | 6f88e12f9dee4a658913b475e7680952c6ff3cac (diff) |
Merge pull request #4608 from khuzemap/master
Add "override" keyword for overridden virtual functions
Diffstat (limited to 'src/google/protobuf/util/message_differencer.h')
-rw-r--r-- | src/google/protobuf/util/message_differencer.h | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/src/google/protobuf/util/message_differencer.h b/src/google/protobuf/util/message_differencer.h index bbcf8498..b3e65515 100644 --- a/src/google/protobuf/util/message_differencer.h +++ b/src/google/protobuf/util/message_differencer.h @@ -597,7 +597,7 @@ class LIBPROTOBUF_EXPORT MessageDifferencer { public: explicit StreamReporter(io::ZeroCopyOutputStream* output); explicit StreamReporter(io::Printer* printer); // delimiter '$' - virtual ~StreamReporter(); + virtual ~StreamReporter() override; // When set to true, the stream reporter will also output aggregates nodes // (i.e. messages and groups) whose subfields have been modified. When @@ -607,32 +607,33 @@ class LIBPROTOBUF_EXPORT MessageDifferencer { } // The following are implementations of the methods described above. + virtual void ReportAdded(const Message& message1, const Message& message2, - const std::vector<SpecificField>& field_path); + const std::vector<SpecificField>& field_path) override; virtual void ReportDeleted(const Message& message1, const Message& message2, - const std::vector<SpecificField>& field_path); + const std::vector<SpecificField>& field_path) override; virtual void ReportModified(const Message& message1, const Message& message2, - const std::vector<SpecificField>& field_path); + const std::vector<SpecificField>& field_path) override; virtual void ReportMoved(const Message& message1, const Message& message2, - const std::vector<SpecificField>& field_path); + const std::vector<SpecificField>& field_path) override; virtual void ReportMatched(const Message& message1, const Message& message2, - const std::vector<SpecificField>& field_path); + const std::vector<SpecificField>& field_path) override; virtual void ReportIgnored(const Message& message1, const Message& message2, - const std::vector<SpecificField>& field_path); + const std::vector<SpecificField>& field_path) override; - virtual void ReportUnknownFieldIgnored( + void ReportUnknownFieldIgnored( const Message& message1, const Message& message2, - const std::vector<SpecificField>& field_path); + const std::vector<SpecificField>& field_path) override; protected: // Prints the specified path of fields to the buffer. message is used to @@ -681,7 +682,7 @@ class LIBPROTOBUF_EXPORT MessageDifferencer { public: explicit MapEntryKeyComparator(MessageDifferencer* message_differencer); virtual bool IsMatch(const Message& message1, const Message& message2, - const std::vector<SpecificField>& parent_fields) const; + const std::vector<SpecificField>& parent_fields) const override; private: MessageDifferencer* message_differencer_; |