Make max/minCoeff templated on index type

See merge request oss/rotgen!23
This commit is contained in:
Joel Falcou 2025-09-18 15:08:10 +02:00
parent c40a947daa
commit d667fd28b5
12 changed files with 157 additions and 18 deletions

View file

@ -331,14 +331,14 @@ struct CLASSNAME::payload
return val;
}
TYPE CLASSNAME::minCoeff(std::ptrdiff_t* row, std::ptrdiff_t* col) const
TYPE CLASSNAME::minCoeff(Index* row, Index* col) const
{
TYPE val{};
storage_->apply([&](const auto& blk) { val = blk.minCoeff(row, col); });
return val;
}
TYPE CLASSNAME::maxCoeff(std::ptrdiff_t* row, std::ptrdiff_t* col) const
TYPE CLASSNAME::maxCoeff(Index* row, Index* col) const
{
TYPE val{};
storage_->apply([&](const auto& blk) { val = blk.maxCoeff(row, col); });