Skip to content

Commit

Permalink
small cleanups
Browse files Browse the repository at this point in the history
  • Loading branch information
lperron committed Jul 22, 2024
1 parent db0c467 commit b19a39c
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion ortools/algorithms/find_graph_symmetries_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ TEST_F(FindSymmetriesTest, CyclesOfDifferentLength) {
// This can be used to convert a list of M undirected edges into the list of
// 2*M corresponding directed arcs.
std::vector<std::pair<int, int>> AppendReversedPairs(
const std::vector<std::pair<int, int>>& pairs) {
absl::Span<const std::pair<int, int>> pairs) {
std::vector<std::pair<int, int>> out;
out.reserve(pairs.size() * 2);
out.insert(out.begin(), pairs.begin(), pairs.end());
Expand Down
2 changes: 1 addition & 1 deletion ortools/sat/precedences.cc
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ void PrecedenceRelations::Build() {
}

void PrecedenceRelations::ComputeFullPrecedences(
const std::vector<IntegerVariable>& vars,
absl::Span<const IntegerVariable> vars,
std::vector<FullIntegerPrecedence>* output) {
output->clear();
if (!is_built_) Build();
Expand Down
2 changes: 1 addition & 1 deletion ortools/sat/precedences.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ class PrecedenceRelations : public ReversibleInterface {
// support the general non-DAG cases.
//
// TODO(user): Many relations can be redundant. Filter them.
void ComputeFullPrecedences(const std::vector<IntegerVariable>& vars,
void ComputeFullPrecedences(absl::Span<const IntegerVariable> vars,
std::vector<FullIntegerPrecedence>* output);

// Returns a set of precedences (var, index) such that var is after
Expand Down
1 change: 0 additions & 1 deletion ortools/sat/python/cp_model_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -1252,7 +1252,6 @@ def testSearchForAllSolutions(self):
status = solver.solve(model, solution_counter)
self.assertEqual(cp_model.OPTIMAL, status)
self.assertEqual(5, solution_counter.solution_count)
model.minimize(x)

def testSolveWithSolutionCallback(self):
print("testSolveWithSolutionCallback")
Expand Down

0 comments on commit b19a39c

Please sign in to comment.