A library for arbitrary ranges in c++