Added filtering according to expected type, when it comes to resolving overloading.