Formatting

This commit is contained in:
Alexander Karatarakis 2017-03-10 17:01:41 -08:00
parent 6860b461a1
commit c59ac4e344
2 changed files with 11 additions and 11 deletions

View File

@ -46,15 +46,15 @@ namespace vcpkg::Environment
const fs::path msvc_path = Strings::format(R"(%s\VC\Tools\MSVC)", instance);
std::vector<fs::path> msvc_subdirectories;
Files::non_recursive_find_matching_paths_in_dir(msvc_path, [&](const fs::path& current)
{
return fs::is_directory(current);
}, &msvc_subdirectories);
{
return fs::is_directory(current);
}, &msvc_subdirectories);
// Sort them so that latest comes first
std::sort(msvc_subdirectories.begin(), msvc_subdirectories.end(), [&](const fs::path& left, const fs::path& right)
{
return left.filename() > right.filename();
});
{
return left.filename() > right.filename();
});
for (const fs::path& subdir : msvc_subdirectories)
{

View File

@ -40,10 +40,10 @@ namespace vcpkg
static optional<fs::path> find_if_has_equal_or_greater_version(const std::vector<fs::path>& candidate_paths, const std::wstring& version_check_arguments, const std::array<int, 3>& expected_version)
{
auto it = std::find_if(candidate_paths.cbegin(), candidate_paths.cend(), [&](const fs::path& p)
{
const std::wstring cmd = Strings::wformat(LR"("%s" %s)", p.native(), version_check_arguments);
return exists_and_has_equal_or_greater_version(cmd, expected_version);
});
{
const std::wstring cmd = Strings::wformat(LR"("%s" %s)", p.native(), version_check_arguments);
return exists_and_has_equal_or_greater_version(cmd, expected_version);
});
if (it != candidate_paths.cend())
{
@ -83,7 +83,7 @@ namespace vcpkg
const fs::path actual_downloaded_path = rc.output;
Checks::check_exit(expected_downloaded_path == actual_downloaded_path, "Expected dependency downloaded path to be %s, but was %s",
expected_downloaded_path.generic_string(), actual_downloaded_path.generic_string());
expected_downloaded_path.generic_string(), actual_downloaded_path.generic_string());
return actual_downloaded_path;
}