diff options
author | Brad King <brad.king@kitware.com> | 2017-12-21 12:59:48 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2017-12-21 12:59:51 (GMT) |
commit | 3ba57ddf895019b378ef0f20716e40e001d67f90 (patch) | |
tree | e538127ca2582c692a51056a263a5ec2d4254975 | |
parent | d0390f8be0a640942892b1dda114f472ff5e0218 (diff) | |
parent | cfe4e2db1fd609fea5da355cd61e0b77e185f258 (diff) | |
download | CMake-3ba57ddf895019b378ef0f20716e40e001d67f90.zip CMake-3ba57ddf895019b378ef0f20716e40e001d67f90.tar.gz CMake-3ba57ddf895019b378ef0f20716e40e001d67f90.tar.bz2 |
Merge topic 'use-override'
cfe4e2db VS: Use 'override' keyword for overridden methods in generator classes
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1601
-rw-r--r-- | Source/cmGlobalVisualStudio10Generator.h | 44 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio11Generator.h | 16 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio12Generator.h | 18 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio14Generator.h | 16 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio15Generator.h | 12 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio71Generator.h | 27 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio7Generator.h | 40 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio8Generator.h | 44 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio9Generator.h | 8 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudioGenerator.h | 10 | ||||
-rw-r--r-- | Source/cmLocalVisualStudio10Generator.h | 10 | ||||
-rw-r--r-- | Source/cmLocalVisualStudio7Generator.h | 12 | ||||
-rw-r--r-- | Source/cmLocalVisualStudioGenerator.h | 4 |
13 files changed, 132 insertions, 129 deletions
diff --git a/Source/cmGlobalVisualStudio10Generator.h b/Source/cmGlobalVisualStudio10Generator.h index fc21193..f2501c2 100644 --- a/Source/cmGlobalVisualStudio10Generator.h +++ b/Source/cmGlobalVisualStudio10Generator.h @@ -18,29 +18,31 @@ public: const std::string& platformName); static cmGlobalGeneratorFactory* NewFactory(); - virtual bool MatchesGeneratorName(const std::string& name) const; + bool MatchesGeneratorName(const std::string& name) const override; - virtual bool SetSystemName(std::string const& s, cmMakefile* mf); - virtual bool SetGeneratorPlatform(std::string const& p, cmMakefile* mf); - virtual bool SetGeneratorToolset(std::string const& ts, cmMakefile* mf); + bool SetSystemName(std::string const& s, cmMakefile* mf) override; + bool SetGeneratorPlatform(std::string const& p, cmMakefile* mf) override; + bool SetGeneratorToolset(std::string const& ts, cmMakefile* mf) override; - virtual void GenerateBuildCommand( - std::vector<std::string>& makeCommand, const std::string& makeProgram, - const std::string& projectName, const std::string& projectDir, - const std::string& targetName, const std::string& config, bool fast, - bool verbose, - std::vector<std::string> const& makeOptions = std::vector<std::string>()); + void GenerateBuildCommand(std::vector<std::string>& makeCommand, + const std::string& makeProgram, + const std::string& projectName, + const std::string& projectDir, + const std::string& targetName, + const std::string& config, bool fast, bool verbose, + std::vector<std::string> const& makeOptions = + std::vector<std::string>()) override; ///! create the correct local generator - virtual cmLocalGenerator* CreateLocalGenerator(cmMakefile* mf); + cmLocalGenerator* CreateLocalGenerator(cmMakefile* mf) override; /** * Try to determine system information such as shared library * extension, pthreads, byte order etc. */ - virtual void EnableLanguage(std::vector<std::string> const& languages, - cmMakefile*, bool optional); - virtual void WriteSLNHeader(std::ostream& fout); + void EnableLanguage(std::vector<std::string> const& languages, cmMakefile*, + bool optional) override; + void WriteSLNHeader(std::ostream& fout) override; bool IsCudaEnabled() const { return this->CudaEnabled; } @@ -87,11 +89,11 @@ public: /** Return true if building for WindowsStore */ bool TargetsWindowsStore() const { return this->SystemIsWindowsStore; } - virtual const char* GetCMakeCFGIntDir() const { return "$(Configuration)"; } + const char* GetCMakeCFGIntDir() const override { return "$(Configuration)"; } bool Find64BitTools(cmMakefile* mf); /** Generate an <output>.rule file path for a given command output. */ - virtual std::string GenerateRuleFile(std::string const& output) const; + std::string GenerateRuleFile(std::string const& output) const override; void PathTooLong(cmGeneratorTarget* target, cmSourceFile const* sf, std::string const& sfRel); @@ -114,7 +116,7 @@ public: cmIDEFlagTable const* GetNasmFlagTable() const; protected: - virtual void Generate(); + void Generate() override; virtual bool InitializeSystem(cmMakefile* mf); virtual bool InitializeWindows(cmMakefile* mf); virtual bool InitializeWindowsCE(cmMakefile* mf); @@ -128,7 +130,7 @@ protected: virtual bool SelectWindowsPhoneToolset(std::string& toolset) const; virtual bool SelectWindowsStoreToolset(std::string& toolset) const; - virtual const char* GetIDEVersion() { return "10.0"; } + const char* GetIDEVersion() override { return "10.0"; } std::string const& GetMSBuildCommand(); @@ -174,8 +176,8 @@ private: bool MSBuildCommandInitialized; cmVisualStudio10ToolsetOptions ToolsetOptions; virtual std::string FindMSBuildCommand(); - virtual std::string FindDevEnvCommand(); - virtual std::string GetVSMakeProgram() { return this->GetMSBuildCommand(); } + std::string FindDevEnvCommand() override; + std::string GetVSMakeProgram() override { return this->GetMSBuildCommand(); } bool PlatformToolsetNeedsDebugEnum; @@ -187,6 +189,6 @@ private: bool CudaEnabled; // We do not use the reload macros for VS >= 10. - virtual std::string GetUserMacrosDirectory() { return ""; } + std::string GetUserMacrosDirectory() override { return ""; } }; #endif diff --git a/Source/cmGlobalVisualStudio11Generator.h b/Source/cmGlobalVisualStudio11Generator.h index 8b75aad..40f02fb 100644 --- a/Source/cmGlobalVisualStudio11Generator.h +++ b/Source/cmGlobalVisualStudio11Generator.h @@ -24,15 +24,15 @@ public: const std::string& platformName); static cmGlobalGeneratorFactory* NewFactory(); - virtual bool MatchesGeneratorName(const std::string& name) const; + bool MatchesGeneratorName(const std::string& name) const override; - virtual void WriteSLNHeader(std::ostream& fout); + void WriteSLNHeader(std::ostream& fout) override; protected: - virtual bool InitializeWindowsPhone(cmMakefile* mf); - virtual bool InitializeWindowsStore(cmMakefile* mf); - virtual bool SelectWindowsPhoneToolset(std::string& toolset) const; - virtual bool SelectWindowsStoreToolset(std::string& toolset) const; + bool InitializeWindowsPhone(cmMakefile* mf) override; + bool InitializeWindowsStore(cmMakefile* mf) override; + bool SelectWindowsPhoneToolset(std::string& toolset) const override; + bool SelectWindowsStoreToolset(std::string& toolset) const override; // Used to verify that the Desktop toolset for the current generator is // installed on the machine. @@ -43,12 +43,12 @@ protected: bool IsWindowsPhoneToolsetInstalled() const; bool IsWindowsStoreToolsetInstalled() const; - virtual const char* GetIDEVersion() { return "11.0"; } + const char* GetIDEVersion() override { return "11.0"; } bool UseFolderProperty(); static std::set<std::string> GetInstalledWindowsCESDKs(); /** Return true if the configuration needs to be deployed */ - virtual bool NeedsDeploy(cmStateEnums::TargetType type) const; + bool NeedsDeploy(cmStateEnums::TargetType type) const override; private: class Factory; diff --git a/Source/cmGlobalVisualStudio12Generator.h b/Source/cmGlobalVisualStudio12Generator.h index 5ba21a6..c941809 100644 --- a/Source/cmGlobalVisualStudio12Generator.h +++ b/Source/cmGlobalVisualStudio12Generator.h @@ -22,32 +22,32 @@ public: const std::string& platformName); static cmGlobalGeneratorFactory* NewFactory(); - virtual bool MatchesGeneratorName(const std::string& name) const; + bool MatchesGeneratorName(const std::string& name) const override; - virtual void WriteSLNHeader(std::ostream& fout); + void WriteSLNHeader(std::ostream& fout) override; // in Visual Studio 2013 they detached the MSBuild tools version // from the .Net Framework version and instead made it have it's own // version number - virtual const char* GetToolsVersion() { return "12.0"; } + const char* GetToolsVersion() override { return "12.0"; } protected: bool ProcessGeneratorToolsetField(std::string const& key, std::string const& value) override; - virtual bool InitializeWindowsPhone(cmMakefile* mf); - virtual bool InitializeWindowsStore(cmMakefile* mf); - virtual bool SelectWindowsPhoneToolset(std::string& toolset) const; - virtual bool SelectWindowsStoreToolset(std::string& toolset) const; + bool InitializeWindowsPhone(cmMakefile* mf) override; + bool InitializeWindowsStore(cmMakefile* mf) override; + bool SelectWindowsPhoneToolset(std::string& toolset) const override; + bool SelectWindowsStoreToolset(std::string& toolset) const override; // Used to verify that the Desktop toolset for the current generator is // installed on the machine. - virtual bool IsWindowsDesktopToolsetInstalled() const; + bool IsWindowsDesktopToolsetInstalled() const override; // These aren't virtual because we need to check if the selected version // of the toolset is installed bool IsWindowsPhoneToolsetInstalled() const; bool IsWindowsStoreToolsetInstalled() const; - virtual const char* GetIDEVersion() { return "12.0"; } + const char* GetIDEVersion() override { return "12.0"; } private: class Factory; }; diff --git a/Source/cmGlobalVisualStudio14Generator.h b/Source/cmGlobalVisualStudio14Generator.h index 425fb22..d92a11a 100644 --- a/Source/cmGlobalVisualStudio14Generator.h +++ b/Source/cmGlobalVisualStudio14Generator.h @@ -22,26 +22,26 @@ public: const std::string& platformName); static cmGlobalGeneratorFactory* NewFactory(); - virtual bool MatchesGeneratorName(const std::string& name) const; + bool MatchesGeneratorName(const std::string& name) const override; - virtual void WriteSLNHeader(std::ostream& fout); + void WriteSLNHeader(std::ostream& fout) override; - virtual const char* GetToolsVersion() { return "14.0"; } + const char* GetToolsVersion() override { return "14.0"; } protected: - virtual bool InitializeWindows(cmMakefile* mf); - virtual bool InitializeWindowsStore(cmMakefile* mf); - virtual bool SelectWindowsStoreToolset(std::string& toolset) const; + bool InitializeWindows(cmMakefile* mf) override; + bool InitializeWindowsStore(cmMakefile* mf) override; + bool SelectWindowsStoreToolset(std::string& toolset) const override; // These aren't virtual because we need to check if the selected version // of the toolset is installed bool IsWindowsStoreToolsetInstalled() const; - virtual const char* GetIDEVersion() { return "14.0"; } + const char* GetIDEVersion() override { return "14.0"; } virtual bool SelectWindows10SDK(cmMakefile* mf, bool required); // Used to verify that the Desktop toolset for the current generator is // installed on the machine. - virtual bool IsWindowsDesktopToolsetInstalled() const; + bool IsWindowsDesktopToolsetInstalled() const override; std::string GetWindows10SDKVersion(); diff --git a/Source/cmGlobalVisualStudio15Generator.h b/Source/cmGlobalVisualStudio15Generator.h index 852a4e7..4f4e0b9 100644 --- a/Source/cmGlobalVisualStudio15Generator.h +++ b/Source/cmGlobalVisualStudio15Generator.h @@ -22,11 +22,11 @@ public: const std::string& platformName); static cmGlobalGeneratorFactory* NewFactory(); - virtual bool MatchesGeneratorName(const std::string& name) const; + bool MatchesGeneratorName(const std::string& name) const override; - virtual void WriteSLNHeader(std::ostream& fout); + void WriteSLNHeader(std::ostream& fout) override; - virtual const char* GetToolsVersion() { return "15.0"; } + const char* GetToolsVersion() override { return "15.0"; } bool SetGeneratorInstance(std::string const& i, cmMakefile* mf) override; @@ -34,13 +34,13 @@ public: protected: bool InitializeWindows(cmMakefile* mf) override; - virtual bool SelectWindowsStoreToolset(std::string& toolset) const; + bool SelectWindowsStoreToolset(std::string& toolset) const override; - virtual const char* GetIDEVersion() { return "15.0"; } + const char* GetIDEVersion() override { return "15.0"; } // Used to verify that the Desktop toolset for the current generator is // installed on the machine. - virtual bool IsWindowsDesktopToolsetInstalled() const; + bool IsWindowsDesktopToolsetInstalled() const override; // These aren't virtual because we need to check if the selected version // of the toolset is installed diff --git a/Source/cmGlobalVisualStudio71Generator.h b/Source/cmGlobalVisualStudio71Generator.h index 0ce02aa..054c342 100644 --- a/Source/cmGlobalVisualStudio71Generator.h +++ b/Source/cmGlobalVisualStudio71Generator.h @@ -17,25 +17,24 @@ public: const std::string& platformName = ""); protected: - virtual void WriteSLNFile(std::ostream& fout, cmLocalGenerator* root, - std::vector<cmLocalGenerator*>& generators); + void WriteSLNFile(std::ostream& fout, cmLocalGenerator* root, + std::vector<cmLocalGenerator*>& generators) override; virtual void WriteSolutionConfigurations( std::ostream& fout, std::vector<std::string> const& configs); - virtual void WriteProject(std::ostream& fout, const std::string& name, - const char* path, const cmGeneratorTarget* t); - virtual void WriteProjectDepends(std::ostream& fout, const std::string& name, - const char* path, - cmGeneratorTarget const* t); - virtual void WriteProjectConfigurations( + void WriteProject(std::ostream& fout, const std::string& name, + const char* path, const cmGeneratorTarget* t) override; + void WriteProjectDepends(std::ostream& fout, const std::string& name, + const char* path, + cmGeneratorTarget const* t) override; + void WriteProjectConfigurations( std::ostream& fout, const std::string& name, cmGeneratorTarget const& target, std::vector<std::string> const& configs, const std::set<std::string>& configsPartOfDefaultBuild, - const std::string& platformMapping = ""); - virtual void WriteExternalProject(std::ostream& fout, - const std::string& name, const char* path, - const char* typeGuid, - const std::set<std::string>& depends); - virtual void WriteSLNHeader(std::ostream& fout); + const std::string& platformMapping = "") override; + void WriteExternalProject(std::ostream& fout, const std::string& name, + const char* path, const char* typeGuid, + const std::set<std::string>& depends) override; + void WriteSLNHeader(std::ostream& fout) override; // Folders are not supported by VS 7.1. virtual bool UseFolderProperty() { return false; } diff --git a/Source/cmGlobalVisualStudio7Generator.h b/Source/cmGlobalVisualStudio7Generator.h index c5aced4..8d1bdc0 100644 --- a/Source/cmGlobalVisualStudio7Generator.h +++ b/Source/cmGlobalVisualStudio7Generator.h @@ -26,11 +26,11 @@ public: std::string const& GetPlatformName() const; ///! Create a local generator appropriate to this Global Generator - virtual cmLocalGenerator* CreateLocalGenerator(cmMakefile* mf); + cmLocalGenerator* CreateLocalGenerator(cmMakefile* mf) override; - virtual bool SetSystemName(std::string const& s, cmMakefile* mf); + bool SetSystemName(std::string const& s, cmMakefile* mf) override; - virtual bool SetGeneratorPlatform(std::string const& p, cmMakefile* mf); + bool SetGeneratorPlatform(std::string const& p, cmMakefile* mf) override; /** * Utilized by the generator factory to determine if this generator @@ -48,19 +48,21 @@ public: * Try to determine system information such as shared library * extension, pthreads, byte order etc. */ - virtual void EnableLanguage(std::vector<std::string> const& languages, - cmMakefile*, bool optional); + void EnableLanguage(std::vector<std::string> const& languages, cmMakefile*, + bool optional) override; /** * Try running cmake and building a file. This is used for dynamically * loaded commands, not as part of the usual build process. */ - virtual void GenerateBuildCommand( - std::vector<std::string>& makeCommand, const std::string& makeProgram, - const std::string& projectName, const std::string& projectDir, - const std::string& targetName, const std::string& config, bool fast, - bool verbose, - std::vector<std::string> const& makeOptions = std::vector<std::string>()); + void GenerateBuildCommand(std::vector<std::string>& makeCommand, + const std::string& makeProgram, + const std::string& projectName, + const std::string& projectDir, + const std::string& targetName, + const std::string& config, bool fast, bool verbose, + std::vector<std::string> const& makeOptions = + std::vector<std::string>()) override; /** * Generate the DSW workspace file. @@ -71,13 +73,13 @@ public: std::string GetGUID(std::string const& name); /** Append the subdirectory for the given configuration. */ - virtual void AppendDirectoryForConfig(const std::string& prefix, - const std::string& config, - const std::string& suffix, - std::string& dir); + void AppendDirectoryForConfig(const std::string& prefix, + const std::string& config, + const std::string& suffix, + std::string& dir) override; ///! What is the configurations directory variable called? - virtual const char* GetCMakeCFGIntDir() const + const char* GetCMakeCFGIntDir() const override { return "$(ConfigurationName)"; } @@ -103,7 +105,7 @@ public: cmIDEFlagTable const* ExtraFlagTable; protected: - virtual void Generate(); + void Generate() override; virtual const char* GetIDEVersion() = 0; std::string const& GetDevEnvCommand(); @@ -129,7 +131,7 @@ protected: cmLocalGenerator* root); virtual void WriteSLNFooter(std::ostream& fout); virtual void WriteSLNHeader(std::ostream& fout) = 0; - virtual std::string WriteUtilityDepend(const cmGeneratorTarget* target); + std::string WriteUtilityDepend(const cmGeneratorTarget* target) override; virtual void WriteTargetsToSolution( std::ostream& fout, cmLocalGenerator* root, @@ -170,7 +172,7 @@ private: char* IntelProjectVersion; std::string DevEnvCommand; bool DevEnvCommandInitialized; - virtual std::string GetVSMakeProgram() { return this->GetDevEnvCommand(); } + std::string GetVSMakeProgram() override { return this->GetDevEnvCommand(); } }; #define CMAKE_CHECK_BUILD_SYSTEM_TARGET "ZERO_CHECK" diff --git a/Source/cmGlobalVisualStudio8Generator.h b/Source/cmGlobalVisualStudio8Generator.h index 4723b83..af83e4f 100644 --- a/Source/cmGlobalVisualStudio8Generator.h +++ b/Source/cmGlobalVisualStudio8Generator.h @@ -18,42 +18,42 @@ public: static cmGlobalGeneratorFactory* NewFactory(); ///! Get the name for the generator. - virtual std::string GetName() const { return this->Name; } + std::string GetName() const override { return this->Name; } /** Get the name of the main stamp list file. */ static std::string GetGenerateStampList(); - virtual void EnableLanguage(std::vector<std::string> const& languages, - cmMakefile*, bool optional); + void EnableLanguage(std::vector<std::string> const& languages, cmMakefile*, + bool optional) override; virtual void AddPlatformDefinitions(cmMakefile* mf); - virtual bool SetGeneratorPlatform(std::string const& p, cmMakefile* mf); + bool SetGeneratorPlatform(std::string const& p, cmMakefile* mf) override; /** * Override Configure and Generate to add the build-system check * target. */ - virtual void Configure(); + void Configure() override; /** * Where does this version of Visual Studio look for macros for the * current user? Returns the empty string if this version of Visual * Studio does not implement support for VB macros. */ - virtual std::string GetUserMacrosDirectory(); + std::string GetUserMacrosDirectory() override; /** * What is the reg key path to "vsmacros" for this version of Visual * Studio? */ - virtual std::string GetUserMacrosRegKeyBase(); + std::string GetUserMacrosRegKeyBase() override; /** Return true if the target project file should have the option LinkLibraryDependencies and link to .sln dependencies. */ - virtual bool NeedLinkLibraryDependencies(cmGeneratorTarget* target); + bool NeedLinkLibraryDependencies(cmGeneratorTarget* target) override; /** Return true if building for Windows CE */ - virtual bool TargetsWindowsCE() const + bool TargetsWindowsCE() const override { return !this->WindowsCEVersion.empty(); } @@ -62,12 +62,12 @@ public: bool IsExpressEdition() const { return this->ExpressEdition; } protected: - virtual void AddExtraIDETargets(); - virtual const char* GetIDEVersion() { return "8.0"; } + void AddExtraIDETargets() override; + const char* GetIDEVersion() override { return "8.0"; } - virtual std::string FindDevEnvCommand(); + std::string FindDevEnvCommand() override; - virtual bool VSLinksDependencies() const { return false; } + bool VSLinksDependencies() const override { return false; } bool AddCheckTarget(); @@ -75,18 +75,18 @@ protected: virtual bool NeedsDeploy(cmStateEnums::TargetType type) const; static cmIDEFlagTable const* GetExtraFlagTableVS8(); - virtual void WriteSLNHeader(std::ostream& fout); - virtual void WriteSolutionConfigurations( - std::ostream& fout, std::vector<std::string> const& configs); - virtual void WriteProjectConfigurations( + void WriteSLNHeader(std::ostream& fout) override; + void WriteSolutionConfigurations( + std::ostream& fout, std::vector<std::string> const& configs) override; + void WriteProjectConfigurations( std::ostream& fout, const std::string& name, cmGeneratorTarget const& target, std::vector<std::string> const& configs, const std::set<std::string>& configsPartOfDefaultBuild, - const std::string& platformMapping = ""); - virtual bool ComputeTargetDepends(); - virtual void WriteProjectDepends(std::ostream& fout, const std::string& name, - const char* path, - const cmGeneratorTarget* t); + const std::string& platformMapping = "") override; + bool ComputeTargetDepends() override; + void WriteProjectDepends(std::ostream& fout, const std::string& name, + const char* path, + const cmGeneratorTarget* t) override; bool UseFolderProperty(); diff --git a/Source/cmGlobalVisualStudio9Generator.h b/Source/cmGlobalVisualStudio9Generator.h index fbc1f5d..37efb9c 100644 --- a/Source/cmGlobalVisualStudio9Generator.h +++ b/Source/cmGlobalVisualStudio9Generator.h @@ -21,23 +21,23 @@ public: * Try to determine system information such as shared library * extension, pthreads, byte order etc. */ - virtual void WriteSLNHeader(std::ostream& fout); + void WriteSLNHeader(std::ostream& fout) override; /** * Where does this version of Visual Studio look for macros for the * current user? Returns the empty string if this version of Visual * Studio does not implement support for VB macros. */ - virtual std::string GetUserMacrosDirectory(); + std::string GetUserMacrosDirectory() override; /** * What is the reg key path to "vsmacros" for this version of Visual * Studio? */ - virtual std::string GetUserMacrosRegKeyBase(); + std::string GetUserMacrosRegKeyBase() override; protected: - virtual const char* GetIDEVersion() { return "9.0"; } + const char* GetIDEVersion() override { return "9.0"; } private: class Factory; friend class Factory; diff --git a/Source/cmGlobalVisualStudioGenerator.h b/Source/cmGlobalVisualStudioGenerator.h index f4fc3cf..75b7f22 100644 --- a/Source/cmGlobalVisualStudioGenerator.h +++ b/Source/cmGlobalVisualStudioGenerator.h @@ -96,7 +96,7 @@ public: /** Return true if the generated build tree may contain multiple builds. i.e. "Can I build Debug and Release in the same tree?" */ - virtual bool IsMultiConfig() const { return true; } + bool IsMultiConfig() const override { return true; } /** Return true if building for Windows CE */ virtual bool TargetsWindowsCE() const { return false; } @@ -122,8 +122,8 @@ public: bool FindMakeProgram(cmMakefile*) override; - virtual std::string ExpandCFGIntDir(const std::string& str, - const std::string& config) const; + std::string ExpandCFGIntDir(const std::string& str, + const std::string& config) const override; void ComputeTargetObjectDirectory(cmGeneratorTarget* gt) const; @@ -137,7 +137,7 @@ public: bool dryRun) override; protected: - virtual void AddExtraIDETargets(); + void AddExtraIDETargets() override; // Does this VS version link targets to each other if there are // dependencies in the SLN file? This was done for VS versions @@ -146,7 +146,7 @@ protected: virtual const char* GetIDEVersion() = 0; - virtual bool ComputeTargetDepends(); + bool ComputeTargetDepends() override; class VSDependSet : public std::set<std::string> { }; diff --git a/Source/cmLocalVisualStudio10Generator.h b/Source/cmLocalVisualStudio10Generator.h index 4cd56dd..bcdc307 100644 --- a/Source/cmLocalVisualStudio10Generator.h +++ b/Source/cmLocalVisualStudio10Generator.h @@ -29,13 +29,13 @@ public: /** * Generate the makefile for this directory. */ - virtual void Generate(); - virtual void ReadAndStoreExternalGUID(const std::string& name, - const char* path); + void Generate() override; + void ReadAndStoreExternalGUID(const std::string& name, + const char* path) override; protected: - virtual const char* ReportErrorLabel() const; - virtual bool CustomCommandUseLocal() const { return true; } + const char* ReportErrorLabel() const override; + bool CustomCommandUseLocal() const override { return true; } private: }; diff --git a/Source/cmLocalVisualStudio7Generator.h b/Source/cmLocalVisualStudio7Generator.h index 48f2e1a..02e6931 100644 --- a/Source/cmLocalVisualStudio7Generator.h +++ b/Source/cmLocalVisualStudio7Generator.h @@ -35,12 +35,12 @@ public: virtual ~cmLocalVisualStudio7Generator(); - virtual void AddHelperCommands(); + void AddHelperCommands() override; /** * Generate the makefile for this directory. */ - virtual void Generate(); + void Generate() override; enum BuildType { @@ -56,12 +56,12 @@ public: */ void SetBuildType(BuildType, const std::string& name); - virtual std::string GetTargetDirectory( - cmGeneratorTarget const* target) const; + std::string GetTargetDirectory( + cmGeneratorTarget const* target) const override; cmSourceFile* CreateVCProjBuildRule(); void WriteStampFiles(); - virtual std::string ComputeLongestObjectDirectory( - cmGeneratorTarget const*) const; + std::string ComputeLongestObjectDirectory( + cmGeneratorTarget const*) const override; virtual void ReadAndStoreExternalGUID(const std::string& name, const char* path); diff --git a/Source/cmLocalVisualStudioGenerator.h b/Source/cmLocalVisualStudioGenerator.h index ace2f89..3fdafd2 100644 --- a/Source/cmLocalVisualStudioGenerator.h +++ b/Source/cmLocalVisualStudioGenerator.h @@ -44,9 +44,9 @@ public: virtual std::string ComputeLongestObjectDirectory( cmGeneratorTarget const*) const = 0; - virtual void ComputeObjectFilenames( + void ComputeObjectFilenames( std::map<cmSourceFile const*, std::string>& mapping, - cmGeneratorTarget const* = 0); + cmGeneratorTarget const* = 0) override; protected: virtual const char* ReportErrorLabel() const; |