fixing return types for Set::extract and Set::classicExtract