Skip to content
Snippets Groups Projects

Add tests for empty RelationTable

Merged Tommaso Fulghesu requested to merge tfulghes-fix-empty-ranges into master
All threads resolved!
@@ -221,6 +221,8 @@ namespace Functors::Functional {
using std::next;
using std::make_pair;
if ( begin( range ) == end( range ) ) throw std::runtime_error( "Attempt to iterate over an empty range" );
auto min_entry = std::accumulate(
next( begin( range ) ), end( range ),
make_pair( *begin( range ), functor( mask_arg, mask, *begin( range ), input... ) ),
@@ -264,6 +266,8 @@ namespace Functors::Functional {
using std::next;
using std::make_pair;
if ( begin( range ) == end( range ) ) throw std::runtime_error( "Attempt to iterate over an empty range" );
auto max_entry = std::accumulate(
next( begin( range ) ), end( range ),
make_pair( *begin( range ), functor( mask_arg, mask, *begin( range ), input... ) ),
Loading