Skip to content

Commit

Permalink
remove substract code
Browse files Browse the repository at this point in the history
  • Loading branch information
alfC committed Dec 23, 2024
1 parent 7d5675e commit 7a2eb4c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions include/boost/multi/detail/layout.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,9 +184,10 @@ struct extensions_t : boost::multi::detail::tuple_prepend_t<index_extension, typ
}
template<class... Indices>
constexpr auto prev_canonical(index& idx, Indices&... rest) const -> bool { // NOLINT(google-runtime-references) idx is mutated
if(extensions_t<D-1>{this->base().tail()}.prev_canonical(rest...)) {--idx;}
if(idx < this->base().head().first()) {
idx = this->base().head().back();
if(extensions_t<D-1>{this->base().tail()}.prev_canonical(rest...)) { --idx; }
if(idx < this->base().head().first()) {
assert(0); // TODO(correaa) implement
// idx = this->base().head().back();
return true;
}
return false;
Expand Down

0 comments on commit 7a2eb4c

Please sign in to comment.