Version bump to 0.40.0