better parsing/lexing; printing error messages