Range : in the `union` factory use assert rather than throw

small optimization, loosen the constrain on what type of error is thrown
for an empty ranges argument