"some" pistols allow you to swap out a 40 barrel with a 9mm one. The M&P Shield can do that for example... (40 to 9mm WILL NOT work the other way around without grinding down some of the barrel - no thanks)
I wouldn't trust it myself but based on everything I've seen, there's some wiggle in the barrel because the slide isn't machined for the 9mm but doesn't affect accuracy.