MACPAS mode

[next] [prev] [prev-tail] [tail] [up]

### D.6 MACPAS mode

This mode is selected by the $MODE MACPAS switch. On the command line, this mode is selected by the -Mmacpas switch. It mainly switches on some extra features:

1. Support for the $SETC directive.
2. Support for the $IFC, $ELSEC and $ENDC directives.
3. Support for the UNDEFINED construct in macros.
4. Support for TRUE and FALSE as values in macro expressions.
5. Macros may be assigned hexadecimal numbers, like $2345.
6. The Implementation keyword can be omitted if the implementation section is empty.
7. The cdecl modifier keyword can be abbreviated to C.
8. UNIV modifier for types in parameter lists is supported.
9. ... (ellipsis) is allowed in procedure declarations, is functionally equal to the varargs keyword.
10. $MODESWITCH nestedprocvars is enabled by default.

(Note: Macros are called ’Compiler Variables’ in Mac OS dialects.)

Currently, the following Mac OS pascal extensions are not yet supported in MACPAS mode:

- External procedures declared in the interface must have the directive External, unless the unit has no Implementation section.
- Cycle instead of Continue.
- Leave instead of Break
- Exit cannot have the name of the procedure to exit as parameter. Instead, for a function the value to return can be supplied as parameter.
- No propagating uses.
- Compiler directives defined in interface sections are not exported.

[next] [prev] [prev-tail] [front] [up]