BARfly Help - BAR Implementation File Reference - File Scope

  Block Declarations

Block declarations can appear in a number of different scopes, but they are most easily understood when declared at file scope.

BlockDeclaration ::= BlockKeyword S BlockType (S 'nofragment')? (S IdentifierName)? S? '{' S? BlockDefinition S? '}' S? ';'

The first identifier, if it appears, uniquely identifies a block type.  The name is an identifier that has not appeared earlier in the file as a construct name, an enumerated constant block name, an enumerated constant name, a global variable name, or a global function name.

If first the identifier is absent from the declaration, the compiler chooses a unique name.  Anonymous declaration of blocks at file scope is not recommended, but it can be done.

The ‘unorganized’ and ‘organized’ attributes cannot both be present for the same declaration.

The ‘nofragment’ attribute is optional.


  See also:  [Global variable declarations] [Global function declarations] [Enumerated constant block declarations]
[Structure declarations] [Block declarations] [List declarations]


BARfly Help Copyright © 2009 Christopher Allen