Skip to content

Language Specification (B) : Implementation Parameters

Benjamin Kowarsch edited this page May 11, 2023 · 2 revisions

Implementation Parameters

Module Impl provides implementation specific constants. Its provision is mandatory. Where any of the constants are dependent on user selectable compiler options, the module may be implemented as a built-in module.

Identity

Constant Type Meaning
ShortName String Literal short name of the language processor
LongName String Literal long name of the language processor
MajorVersion Whole Number major version of the language processor
MinorVersion Whole Number minor version of the language processor
SubMinorVersion Whole Number sub-minor version of the language processor
BuildNumber Whole Number build number of the language processor
HostEnvironment String Literal name of the host environment or operating system

Capability Flags

Boolean Constant indicates whether language processor supports ...
SupportsM2BSK Modula-2 R10 Bootstrap Kernel (M2BSK) subset
SupportsM2R10 Modula-2 R10 (M2R10) full specification
SupportsUnicode type UNICHAR and its operations
SupportsUtf8Source source files encoded in UTF-8
SupportsCFFI C foreign function interface and <*FFI="C"*> pragma
SupportsCLRFFI Microsoft CLR FFI and <*FFI="CLR"*> pragma
SupportsJVMFFI Java Virtual Machine FFI and <*FFI="CLR"*> pragma

Implementation Limits

Whole Number Constant indicates ... required
MaxIdentLength maximum significant length of identifiers ≥ 31
MaxNumLiteralLength maximum length of number literals ≥ 40
MaxStrLiteralLength maximum length of string literals ≥ 120
MaxLineCounter maximum value of line counter for error messages ≥ 32000
MaxColumnCounter maximum value of column counter for error messages ≥ 160
MaxEnumValues maximum number of values of an enumeration type ≥ 4096
MaxSetElements maximum number of elements in an enumerated set ≥ 128
MaxProcNestLevel maximum nesting level of local procedures ≥ 2
Clone this wiki locally