8.2.1 Statement lists
Collapse the table of content
Expand the table of content
This documentation is archived and is not being maintained.

8.2.1 Statement lists

Visual Studio .NET 2003

A statement list consists of one or more statements written in sequence. Statement lists occur in blocks (Section 8.2) and in switch-blocks (Section 8.7.2).

statement-list:
statement
statement-list   statement

A statement list is executed by transferring control to the first statement. When and if control reaches the end point of a statement, control is transferred to the next statement. When and if control reaches the end point of the last statement, control is transferred to the end point of the statement list.

A statement in a statement list is reachable if at least one of the following is true:

  • The statement is the first statement and the statement list itself is reachable.
  • The end point of the preceding statement is reachable.
  • The statement is a labeled statement and the label is referenced by a reachable goto statement.

The end point of a statement list is reachable if the end point of the last statement in the list is reachable.

Show:
© 2016 Microsoft