diff options
author | Brad King <brad.king@kitware.com> | 2021-06-17 11:30:48 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2021-06-17 11:54:48 (GMT) |
commit | 3fd65f5ca601d38c7b2ee8c99b148df31cea1acd (patch) | |
tree | e36f7bd076f484ca5148a383fbaf4aeec8d2d673 /Source/cmVSSetupHelper.cxx | |
parent | c92595be1d7c0ae3cd4ea8ff0ce27ede37f676e8 (diff) | |
download | CMake-3fd65f5ca601d38c7b2ee8c99b148df31cea1acd.zip CMake-3fd65f5ca601d38c7b2ee8c99b148df31cea1acd.tar.gz CMake-3fd65f5ca601d38c7b2ee8c99b148df31cea1acd.tar.bz2 |
VS: Compare VS instance versions as strings
This makes the values more readable.
Diffstat (limited to 'Source/cmVSSetupHelper.cxx')
-rw-r--r-- | Source/cmVSSetupHelper.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/Source/cmVSSetupHelper.cxx b/Source/cmVSSetupHelper.cxx index 9626599..969a2c2 100644 --- a/Source/cmVSSetupHelper.cxx +++ b/Source/cmVSSetupHelper.cxx @@ -258,15 +258,13 @@ bool cmVSSetupAPIHelper::GetVSInstanceInfo(std::string& vsInstallLocation) return isInstalled; } -bool cmVSSetupAPIHelper::GetVSInstanceVersion( - unsigned long long& vsInstanceVersion) +bool cmVSSetupAPIHelper::GetVSInstanceVersion(std::string& vsInstanceVersion) { - vsInstanceVersion = 0; + vsInstanceVersion.clear(); bool isInstalled = this->EnumerateAndChooseVSInstance(); if (isInstalled) { - vsInstanceVersion = - static_cast<unsigned long long>(chosenInstanceInfo.ullVersion); + vsInstanceVersion = cmsys::Encoding::ToNarrow(chosenInstanceInfo.Version); } return isInstalled; |