summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Andres Klode <julian.klode@canonical.com>2024-07-02 18:56:40 +0200
committerJulian Andres Klode <julian.klode@canonical.com>2024-07-02 20:10:33 +0200
commita16350427b8ce3865d2f11e637952210d34ee410 (patch)
treedd7f7f9b0a2dce8ed6d4913e605489ebf025738e
parentae141932d8b434098e3f77c75c428ca8caff9a6e (diff)
solver3: Formatting cleanup
Run clang-format
-rw-r--r--apt-pkg/solver3.cc16
1 files changed, 8 insertions, 8 deletions
diff --git a/apt-pkg/solver3.cc b/apt-pkg/solver3.cc
index 54f66ccd2..67aa68dca 100644
--- a/apt-pkg/solver3.cc
+++ b/apt-pkg/solver3.cc
@@ -155,8 +155,8 @@ class DefaultRootSetFunc2 : public pkgDepCache::DefaultRootSetFunc
std::unique_ptr<APT::CacheFilter::Matcher> Kernels;
public:
- DefaultRootSetFunc2(pkgCache *cache) : Kernels(APT::KernelAutoRemoveHelper::GetProtectedKernelsFilter(cache)){};
- virtual ~DefaultRootSetFunc2(){};
+ DefaultRootSetFunc2(pkgCache *cache) : Kernels(APT::KernelAutoRemoveHelper::GetProtectedKernelsFilter(cache)) {};
+ virtual ~DefaultRootSetFunc2() {};
bool InRootSet(const pkgCache::PkgIterator &pkg) APT_OVERRIDE { return pkg.end() == false && ((*Kernels)(pkg) || DefaultRootSetFunc::InRootSet(pkg)); };
}; // FIXME: DEDUP with pkgDepCache.
@@ -306,7 +306,7 @@ bool APT::Solver::Install(pkgCache::PkgIterator Pkg, Reason reason, Group group)
// Note decision
if (unlikely(debug >= 1))
std::cerr << "[" << depth() << "] Install:" << Pkg.FullName() << " (" << WhyStr(reason) << ")\n";
- (*this)[Pkg] = {reason, depth(), Decision::MUST,};
+ (*this)[Pkg] = {reason, depth(), Decision::MUST};
// Insert the work item.
Work workItem{Reason(Pkg), depth(), group};
@@ -356,9 +356,9 @@ bool APT::Solver::Install(pkgCache::VerIterator Ver, Reason reason, Group group)
// Note decision
if (unlikely(debug >= 1))
std::cerr << "[" << depth() << "] Install:" << Ver.ParentPkg().FullName() << "=" << Ver.VerStr() << " (" << WhyStr(reason) << ")\n";
- (*this)[Ver] = {reason, depth(), Decision::MUST,};
+ (*this)[Ver] = {reason, depth(), Decision::MUST};
if ((*this)[Ver.ParentPkg()].decision != Decision::MUST)
- (*this)[Ver.ParentPkg()] = {Reason(Ver), depth(), Decision::MUST,};
+ (*this)[Ver.ParentPkg()] = {Reason(Ver), depth(), Decision::MUST};
for (auto OV = Ver.ParentPkg().VersionList(); not OV.end(); ++OV)
{
@@ -395,7 +395,7 @@ bool APT::Solver::Reject(pkgCache::PkgIterator Pkg, Reason reason, Group group)
// Reject the package and its versions.
if (unlikely(debug >= 1))
std::cerr << "[" << depth() << "] Reject:" << Pkg.FullName() << " (" << WhyStr(reason) << ")\n";
- (*this)[Pkg] = {reason, depth(), Decision::MUSTNOT,};
+ (*this)[Pkg] = {reason, depth(), Decision::MUSTNOT};
for (auto ver = Pkg.VersionList(); not ver.end(); ver++)
if (not Reject(ver, Reason(Pkg), group))
return false;
@@ -408,7 +408,7 @@ bool APT::Solver::Reject(pkgCache::PkgIterator Pkg, Reason reason, Group group)
// \brief Do not install this version
bool APT::Solver::Reject(pkgCache::VerIterator Ver, Reason reason, Group group)
{
- (void) group;
+ (void)group;
if ((*this)[Ver].decision == Decision::MUSTNOT)
return true;
@@ -423,7 +423,7 @@ bool APT::Solver::Reject(pkgCache::VerIterator Ver, Reason reason, Group group)
// Mark the package as rejected and propagate up as needed.
if (unlikely(debug >= 1))
std::cerr << "[" << depth() << "] Reject:" << Ver.ParentPkg().FullName() << "=" << Ver.VerStr() << " (" << WhyStr(reason) << ")\n";
- (*this)[Ver] = {reason, depth(), Decision::MUSTNOT,};
+ (*this)[Ver] = {reason, depth(), Decision::MUSTNOT};
if (auto pkg = Ver.ParentPkg(); (*this)[pkg].decision != Decision::MUSTNOT)
{
bool anyInstallable = false;