Added template function select_if() in variant.h; Unit-tested.