Syntax
The body section contains the actual code, as well as things like type definitions. Every "thing" in ARF that has global scope is called a section.
Sections start with a name token that is four letters long, and determines what kind of section it is. It then has a permission token, and then a name which defines the name of the section. There may be more tokens after the name depending on what type of section it is. If the section's information does not fit on one line, it will have an indented block underneath it with its content.
There are 6 different types of sections that ARF supports:
- type: Type definitions
- enum: Enums
- face: Interfaces and function pointer types
- data: Global variables
- func: Functions and methods
Semantics
Section definitions are hoisted so there is no need for prototyping things. All sections in a module must have a unique name within that module no matter what kind of section it is. The only exception to this is methods. Method names need only be unique in the context of each reciever.
- Home Page
- List of Pages
- Guidelines
- Language Reference/Design Spec
- Compiler Design