Mercury/amalgram fillings isn't the best example, but biocompatibility is still the primary constraint.
Mayo clinic has a good overview and timeline regarding the discovery process for cobalt-chromium, which was previously thought to be a good all-around implant material: