Specifified templatization of add_subset_to_maps.