3.10 is parsed as a number and it is trimmed to 3.1. That is expected behavior for numbers, but it's crazy for versions.