Trailing zeros are already removed inside the function FloatToString, that is called immediately before the lines deleted by this commit.