﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
297	expressions are not statements	Stephen Siegel	stachnik	"In the AST package, we now have ExpressionNodeIF extending StatementNodeIF.  However, this does not correspond to the syntax of C or any of the other languages under consideration.   According to the C99 Standard, expressions are not statements, but one of the kinds of statements is an ""expression statement"", which wraps an expression.    In a statement such as

lab: x*(y+1);

clearly (y+1) is not a statement.  Labels cannot be associated to it.  This statement is not a compound statement.   There is only one statement there.

Let us discuss here the ramifications of the following changes, before doing anything:

Proposed Changes:

Delete ""implements StatementNodeIF"" from  ExpressionNodeIF.
In ast/IF, move expression package up one level, outside of the statement package.
Add a new statement node: ExpressionStatementNodeIF.  It has one child, which is an ExpressionNodeIF.
Add factory method to create an ExpressionStatementNodeIF.

Implementation classes will have to be modified accordingly.

XML and XML parser will have to be changed accordingly.


"	defect	assigned	major	1.1	ast	1.1		expression statement	
