2005/5/9

     
 

CfgScript block Statement

artefaktur

| Expression statement | block {} Statement | Branch Statements | Loop Statements | Type Declaration | Variable Declaration | Synchronize Statements | With Statement | Using Statement | Type Alias |

The block statement groups multiple statements.


BlockStatement
: '{' Statmenent* '}'
At every place, where the grammar expects one statement, with a block multiple statements can be bound to one statement.

if (a == b)
  a = c; // one statement
else
{ // also one statement through block 
  b = d;
  a = 2;
}

Another effect of a BlockStatement is a block establish a new local scope for local variables. See for more information at  Scoped Variables.