Redefine r_set_select()

This PR brings with it a complete redefinition of `r_set_select()`.
It is now possible to process selected elements using a user defined function or insert selected elements into another set by passing `r_set_insert` as `procf` and the destination set as `dest`.
Wouldn't it make sense to switch the parameter order, as all other functions a user can pass to our library (e.g. through the config) gets the extra parameter as last one?