make RMF_FOREACH work with pre-c++11 boost
fix backward compatibility irange stuff
don't use c++11 constructors
work around old boost