An upper limit to the masses of stars