remove_plan_type -> RemovePlanType
MODIFY
include/vcpkg_Dependencies.h
include/vcpkg_Dependencies.h
@@ -44,7 +44,7 @@ namespace vcpkg::Dependencies
InstallPlanAction plan;
};
- enum class remove_plan_type
+ enum class RemovePlanType
{
UNKNOWN,
NOT_INSTALLED,
@@ -54,14 +54,14 @@ namespace vcpkg::Dependencies
struct remove_plan_action
{
remove_plan_action();
- remove_plan_action(const remove_plan_type& plan_type, const RequestType& request_type);
+ remove_plan_action(const RemovePlanType& plan_type, const RequestType& request_type);
remove_plan_action(const remove_plan_action&) = delete;
remove_plan_action(remove_plan_action&&) = default;
remove_plan_action& operator=(const remove_plan_action&) = delete;
remove_plan_action& operator=(remove_plan_action&&) = default;
- remove_plan_type plan_type;
+ RemovePlanType plan_type;
RequestType request_type;
};

MODIFY
src/commands_remove.cpp
src/commands_remove.cpp
namespace vcpkg::Commands::Remove
{
using Dependencies::package_spec_with_remove_plan;
- using Dependencies::remove_plan_type;
+ using Dependencies::RemovePlanType;
using Dependencies::RequestType;
using Update::OutdatedPackage;
@@ -116,13 +116,13 @@ namespace vcpkg::Commands::Remove
for (const package_spec_with_remove_plan& i : plan)
{
- if (i.plan.plan_type == remove_plan_type::NOT_INSTALLED)
+ if (i.plan.plan_type == RemovePlanType::NOT_INSTALLED)
{
not_installed.push_back(&i);
continue;
}
- if (i.plan.plan_type == remove_plan_type::REMOVE)
+ if (i.plan.plan_type == RemovePlanType::REMOVE)
{
remove.push_back(&i);
continue;
@@ -230,15 +230,15 @@ namespace vcpkg::Commands::Remove
switch (action.plan.plan_type)
{
- case remove_plan_type::NOT_INSTALLED:
+ case RemovePlanType::NOT_INSTALLED:
System::println(System::color::success, "Package %s is not installed", display_name);
break;
- case remove_plan_type::REMOVE:
+ case RemovePlanType::REMOVE:
System::println("Removing package %s... ", display_name);
remove_package(paths, action.spec, &status_db);
System::println(System::color::success, "Removing package %s... done", display_name);
break;
- case remove_plan_type::UNKNOWN:
+ case RemovePlanType::UNKNOWN:
default:
Checks::unreachable(VCPKG_LINE_INFO);
}

MODIFY
src/vcpkg_Dependencies.cpp
src/vcpkg_Dependencies.cpp
@@ -22,11 +22,11 @@ namespace vcpkg::Dependencies
{
}
- remove_plan_action::remove_plan_action() : plan_type(remove_plan_type::UNKNOWN), request_type(RequestType::UNKNOWN)
+ remove_plan_action::remove_plan_action() : plan_type(RemovePlanType::UNKNOWN), request_type(RequestType::UNKNOWN)
{
}
- remove_plan_action::remove_plan_action(const remove_plan_type& plan_type, const Dependencies::RequestType& request_type) : plan_type(plan_type), request_type(request_type)
+ remove_plan_action::remove_plan_action(const RemovePlanType& plan_type, const Dependencies::RequestType& request_type) : plan_type(plan_type), request_type(request_type)
{
}
@@ -124,7 +124,7 @@ namespace vcpkg::Dependencies
const StatusParagraphs::const_iterator it = status_db.find(spec);
if (it == status_db.end() || (*it)->state == InstallState::NOT_INSTALLED)
{
- was_examined.emplace(spec, remove_plan_action(remove_plan_type::NOT_INSTALLED, RequestType::USER_REQUESTED));
+ was_examined.emplace(spec, remove_plan_action(RemovePlanType::NOT_INSTALLED, RequestType::USER_REQUESTED));
continue;
}
@@ -146,7 +146,7 @@ namespace vcpkg::Dependencies
}
const RequestType request_type = specs_as_set.find(spec) != specs_as_set.end() ? RequestType::USER_REQUESTED : RequestType::AUTO_SELECTED;
- was_examined.emplace(spec, remove_plan_action(remove_plan_type::REMOVE, request_type));
+ was_examined.emplace(spec, remove_plan_action(RemovePlanType::REMOVE, request_type));
}
std::vector<package_spec_with_remove_plan> ret;

remove_plan_type -> RemovePlanType