parser.cpp: fixed output from parser to output data structure