Jelajahi Sumber

clang-modernize -add-override on headers

Nils Maier 12 tahun lalu
induk
melakukan
3b9988251f

+ 1 - 1
src/AbstractOptionHandler.h

@@ -126,7 +126,7 @@ public:
 
   virtual bool getCumulative() const CXX11_OVERRIDE;
 
-  virtual void setCumulative(bool f);
+  virtual void setCumulative(bool f) CXX11_OVERRIDE;
 
   enum Flag {
     FLAG_HIDDEN = 1,

+ 1 - 1
src/AbstractProxyResponseCommand.h

@@ -46,7 +46,7 @@ class AbstractProxyResponseCommand : public AbstractCommand {
 private:
   std::shared_ptr<HttpConnection> httpConnection_;
 protected:
-  virtual bool executeInternal();
+  virtual bool executeInternal() CXX11_OVERRIDE;
 
   const std::shared_ptr<HttpConnection>& getHttpConnection() const
   {

+ 1 - 1
src/Exception.h

@@ -81,7 +81,7 @@ public:
 
   virtual ~Exception() throw();
 
-  virtual const char* what() const throw();
+  virtual const char* what() const throw() CXX11_OVERRIDE;
 
   std::string stackTrace() const;
 

+ 1 - 1
src/HandshakeExtensionMessage.h

@@ -63,7 +63,7 @@ private:
 public:
   HandshakeExtensionMessage();
 
-  virtual std::string getPayload();
+  virtual std::string getPayload() CXX11_OVERRIDE;
 
   virtual uint8_t getExtensionMessageID() const CXX11_OVERRIDE
   {

+ 1 - 1
src/HttpResponseCommand.h

@@ -85,7 +85,7 @@ private:
 #endif // ENABLE_MESSAGE_DIGEST
 
 protected:
-  bool executeInternal();
+  bool executeInternal() CXX11_OVERRIDE;
 
   bool shouldInflateContentEncoding(HttpResponse* httpResponse);
 

+ 3 - 3
src/IOFile.h

@@ -68,16 +68,16 @@ public:
   // wrapper for fclose
   int close();
   // wrapper for fflush
-  int flush();
+  int flush() CXX11_OVERRIDE;
   // Return true if file is opened && feof(fp_) != 0. Otherwise
   // returns false.
   bool eof();
   // Returns true if file supports ANSI color escape codes.
-  bool supportsColor();
+  bool supportsColor() CXX11_OVERRIDE;
   // Convenient method. Read data to end of file and write them into
   // given stream. Returns written size.
   size_t transfer(std::ostream& out);
-  int vprintf(const char* format, va_list va);
+  int vprintf(const char* format, va_list va) CXX11_OVERRIDE;
   // Mode for reading
   static const char READ[];
   // Mode for writing