cleaned up some code errors including a possible memory leak with the
tokenizer in the parser