adding basic argument checking to parse_string an parse_number helper functions