diff options
| author | Richard Qin <richard.qin.x@gmail.com> | 2026-04-04 05:21:26 +0800 |
|---|---|---|
| committer | Richard Qin <richard.qin.x@gmail.com> | 2026-04-04 05:21:26 +0800 |
| commit | 593a94a3c13aff82b31fd6c61e0ae07b97a2e426 (patch) | |
| tree | e58a8954b00d412c5f5c5e80bda6b31029dbe138 /proofsearch/src/simplify | |
| parent | 9a5dd39accb75618dc40b5b4f4a3c059cacf6e04 (diff) | |
| download | rcc-project-593a94a3c13aff82b31fd6c61e0ae07b97a2e426.tar.gz rcc-project-593a94a3c13aff82b31fd6c61e0ae07b97a2e426.tar.xz | |
style: reformat codebase with consistent indentation
Diffstat (limited to 'proofsearch/src/simplify')
| -rw-r--r-- | proofsearch/src/simplify/subsumption.cc | 31 | ||||
| -rw-r--r-- | proofsearch/src/simplify/tautology.cc | 21 |
2 files changed, 26 insertions, 26 deletions
diff --git a/proofsearch/src/simplify/subsumption.cc b/proofsearch/src/simplify/subsumption.cc index cf243c9..3756d82 100644 --- a/proofsearch/src/simplify/subsumption.cc +++ b/proofsearch/src/simplify/subsumption.cc @@ -18,25 +18,24 @@ #include "atp/simplify/subsumption.h" - namespace atp { - bool subsumes(const Clause& general, const Clause& specific) { - if (general.size() > specific.size()) { - return false; - } - for (const auto& lit_g : general.literals) { - bool found = false; - for (const auto& lit_s : specific.literals) { - if (lit_g.atom == lit_s.atom && lit_g.is_positive == lit_s.is_positive) { - found = true; - break; - } - } - if (!found) { - return false; +bool subsumes(const Clause& general, const Clause& specific) { + if (general.size() > specific.size()) { + return false; + } + for (const auto& lit_g : general.literals) { + bool found = false; + for (const auto& lit_s : specific.literals) { + if (lit_g.atom == lit_s.atom && lit_g.is_positive == lit_s.is_positive) { + found = true; + break; } } - return true; + if (!found) { + return false; + } } + return true; } +} // namespace atp diff --git a/proofsearch/src/simplify/tautology.cc b/proofsearch/src/simplify/tautology.cc index d41ecd7..70bdced 100644 --- a/proofsearch/src/simplify/tautology.cc +++ b/proofsearch/src/simplify/tautology.cc @@ -17,18 +17,19 @@ */ #include "atp/simplify/tautology.h" + #include <cstddef> - namespace atp { - bool isTautology(const Clause& clause) { - for (size_t i = 0; i < clause.size(); ++i) { - for (size_t j = i + 1; j < clause.size(); ++j) { - if (clause.literals[i].atom == clause.literals[j].atom && - clause.literals[i].is_positive != clause.literals[j].is_positive) { - return true; - } +namespace atp { +bool isTautology(const Clause& clause) { + for (size_t i = 0; i < clause.size(); ++i) { + for (size_t j = i + 1; j < clause.size(); ++j) { + if (clause.literals[i].atom == clause.literals[j].atom && + clause.literals[i].is_positive != clause.literals[j].is_positive) { + return true; } } - return false; } -}
\ No newline at end of file + return false; +} +} // namespace atp
\ No newline at end of file |
