Opened 15 years ago

#278 new defect

array literal parse problems in TreeParser

Reported by: Stephen Siegel Owned by:
Priority: major Milestone: 1.1
Component: front Version: 1.1
Keywords: array literal Cc:

Description

Array literals are sometimes parsed incorrectly. See test2 in example literal directory. Literal {{1,2},{3,4},{5,6}} is interpreted as {{5,6}}.

Also, the front end forbids array declarations in which the extent is not specified, e.g. "int x[];" However there are cases where this should be allowed, as in "int x[]={1,2,3};". See test3 in literal. The front end should just not check for this and leave it to the model layer to throw a syntax exception in the right places.

Change History (0)

Note: See TracTickets for help on using tickets.