outdated_package -> OutdatedPackage
MODIFY
include/vcpkg_Commands.h
include/vcpkg_Commands.h
@@ -59,15 +59,15 @@ namespace vcpkg::Commands
namespace Update
{
- struct outdated_package
+ struct OutdatedPackage
{
- static bool compare_by_name(const outdated_package& left, const outdated_package& right);
+ static bool compare_by_name(const OutdatedPackage& left, const OutdatedPackage& right);
PackageSpec spec;
version_diff_t version_diff;
};
- std::vector<outdated_package> find_outdated_packages(const vcpkg_paths& paths, const StatusParagraphs& status_db);
+ std::vector<OutdatedPackage> find_outdated_packages(const vcpkg_paths& paths, const StatusParagraphs& status_db);
void perform_and_exit(const VcpkgCmdArguments& args, const vcpkg_paths& paths);
}

MODIFY
src/commands_update.cpp
src/commands_update.cpp
namespace vcpkg::Commands::Update
{
- bool outdated_package::compare_by_name(const outdated_package& left, const outdated_package& right)
+ bool OutdatedPackage::compare_by_name(const OutdatedPackage& left, const OutdatedPackage& right)
{
return left.spec.name() < right.spec.name();
}
- std::vector<outdated_package> find_outdated_packages(const vcpkg_paths& paths, const StatusParagraphs& status_db)
+ std::vector<OutdatedPackage> find_outdated_packages(const vcpkg_paths& paths, const StatusParagraphs& status_db)
{
const std::vector<SourceParagraph> source_paragraphs = Paragraphs::load_all_ports(paths.ports);
const std::map<std::string, version_t> src_names_to_versions = Paragraphs::extract_port_names_and_versions(source_paragraphs);
const std::vector<StatusParagraph*> installed_packages = get_installed_ports(status_db);
- std::vector<outdated_package> output;
+ std::vector<OutdatedPackage> output;
for (const StatusParagraph* pgh : installed_packages)
{
auto it = src_names_to_versions.find(pgh->package.spec.name());
@@ -44,8 +44,8 @@ namespace vcpkg::Commands::Update
const StatusParagraphs status_db = database_load_check(paths);
- const auto outdated_packages = SortedVector<outdated_package>(find_outdated_packages(paths, status_db),
- &outdated_package::compare_by_name);
+ const auto outdated_packages = SortedVector<OutdatedPackage>(find_outdated_packages(paths, status_db),
+ &OutdatedPackage::compare_by_name);
if (outdated_packages.empty())
{

outdated_package -> OutdatedPackage