From 837b65722abcf0a1fb8584a22f1a3dac104d6089 Mon Sep 17 00:00:00 2001 From: Michael Sinelnikov Date: Sun, 29 Dec 2024 18:29:51 +0300 Subject: [PATCH] Use v.empty() instead of !v.size() --- src/core/algorithms/dd/split/split.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/core/algorithms/dd/split/split.cpp b/src/core/algorithms/dd/split/split.cpp index 9ccf7102a..5da6af6d3 100644 --- a/src/core/algorithms/dd/split/split.cpp +++ b/src/core/algorithms/dd/split/split.cpp @@ -605,7 +605,7 @@ inline std::list
Split::MergeReducedResults(std::list
const& base_dds, std::list
Split::NegativePruningReduce(DF const& rhs, std::vector const& search, unsigned& cnt) { - if (!search.size()) return {}; + if (search.empty()) return {}; DF const last_df = search.back(); @@ -618,7 +618,7 @@ std::list
Split::NegativePruningReduce(DF const& rhs, std::vector const& auto const [prune, remainder] = NegativeSplit(search, last_df); std::list
dds = NegativePruningReduce(rhs, prune, cnt); - if (!dds.size() && IsFeasible(last_df)) dds.emplace_back(last_df, rhs); + if (dds.empty() && IsFeasible(last_df)) dds.emplace_back(last_df, rhs); std::list
const remaining_dds = NegativePruningReduce(rhs, remainder, cnt); std::list
merged_dds = MergeReducedResults(dds, remaining_dds); @@ -629,7 +629,7 @@ std::list
Split::NegativePruningReduce(DF const& rhs, std::vector const& std::list
Split::HybridPruningReduce(DF const& rhs, std::vector const& search, unsigned& cnt) { - if (!search.size()) return {}; + if (search.empty()) return {}; std::list
dds; DF const first_df = search.front(); @@ -664,7 +664,7 @@ std::list
Split::HybridPruningReduce(DF const& rhs, std::vector const& s std::list
Split::InstanceExclusionReduce(std::vector const& tuple_pair_indices, std::vector const& search, DF const& rhs, unsigned& cnt) { - if (!search.size()) return {}; + if (search.empty()) return {}; std::list
dds; DF const first_df = search.front();