fix switch parsing of negative values