Per @mlucy, use rcheck_datum.
Per @mlucy, use const auto & for these loops.