Fixed bug in the parser and added testcase for it test3.cpp.