library m2f.png reference

m2f homepage
m2f frequently asked questions
m2f manpage
m2f release notes
free modula-2 pages
download pages (tar.gz)
Args.def
Args.mod
ASCII.def
ASCII.mod
Assertion.def
Assertion.mod
Break.def
Break.mod
CmdArgs.def
CmdArgs.mod
Debug.def
Debug.mod
DebugPMD.def
DebugPMD.mod
DiskIO.def
DiskIO.mod
Environment.def
Environment.mod
FileSystem.def
FileSystem.mod
FIO.def
FIO.mod
FpuIO.def
FpuIO.mod
IO.def
IO.mod
libc.c
libc.def
libc.h
LowLevel.c
LowLevel.def
M2RTS.def
M2RTS.mod
MATH.def
MATH.mod
MemUtils.def
MemUtils.mod
NumberIO.def
NumberIO.mod
Scan.def
Scan.mod
Selective.c
Selective.def
StdIO.def
StdIO.mod
Storgae.def
Storage.mod
StrCase.def
StrCase.mod
StrIO.def
StrIO.mod
StrLib.def
StrLib.mod
SysStorage.def
SysStorage.mod
SYSTEM.def
SYSTEM.mod
TimeDate.c
TimeDate.def
TimeString.def
TimeString.mod
UnixArgs.c
UnixArgs.def
wrapc.c
wrapc.def


Here's a short description of the compiler taken from a paper by Gaius Mulley and Keith Verheyden (Department of Computer Studies, University of Glamorgan): Enhancing a Modula-2 compiler to help students learn interactively within the Ceilidh system (As far as I know m2f is the only PIM2 Modula-2 compiler):

The design and implementation of the compiler commenced in 1987 as part of a research project and was based on the 2nd edition Programming in Modula-2. As far as level one students are concerned, the major difference between the 2nd edition and later editions is that identifiers must explicitly be exported from the definition module. It is believed that this is useful when learning about definition and implementation modules, requires discipline from the student and reinforces the reason for the definition module. It also provides the user of a definition module with a brief list of all exported identifiers.
Another attractive feature from the compiler implementor's viewpoint is the ease at which Modula-2 can be integrated with C and thus the UNIX operating system. Identifiers which are qualified on export have the module name prefixed to them in the assembler and object file. Identifiers which are not qualified on export do not have the module name prefixed, thus definition modules can be easily written for corresponding C files.
The compiler has been implemented using a recursive descent parser and produces quadruples as intermediate code. The 80[345]86 code generator is very simple but mature and reliable, the compiler has been used by staff and final year students since 1994.



webcpp.png