Objective Modula-2 Compiler
The Objective Modula-2 compiler is a cross-platform object oriented Modula-2 compiler with native support for Cocoa (Mac OS X), Cocoa Touch (iPhone) and GNUstep (*nix).
Experimental translators for translating early drafts of Objective Modula-2 to Objective-C have been under development since 2006. These translators were single pass pre-processors that produced output by expanding text-templates using a general purpose template engine. They were not intended for software development but for testing ideas and concepts for the emerging language extensions for Cocoa and GNUstep support.
As the language definition has matured, a new compiler, in part derived from an earlier translator, is being developed with the aim to produce a reference implementation for use by the general public. This compiler is written by hand in the C language in order to maximise portability. Once completed, the compiler will consist of a recursive descent parser that builds an abstract syntax tree, and two code generators, one for Objective-C source to be post-compiled by an Objective-C compiler, the other for LLVM IR assembly to be post-processed by LLVM.
Source code for the compiler is being made available under an amended BSD license. However, source files which have an impact on the syntax are currently released under a peer review license. These files will be relicensed under the amended BSD license when the grammar has been finalised and a working front end for the finalised grammar has been completed.
Aliases and build parameters
Filenames and file extensions
Memory management and key value storage
Tables of reserved words, pragmas, built-in identifiers and tokens
- objm2_reserved_word_table.h
- objm2_pragma_ident_table.h
- objm2_builtin_ident_table.h
- objm2_token_table.h
- objm2_production_table.h
Lexical analysis
- objm2_reserved_words.h
- objm2_reserved_words.c
- objm2_tokens.h
- objm2_tokens.c
- objm2_lexer.h
- objm2_lexer.c
Syntax analysis
- objm2_productions.h
- objm2_productions.c
- objm2_first_follow.h
- objm2_tokenset.h
- objm2_tokenset.c
- objm2_parser.h
- objm2_parser.c currently being revised
Code generation
Driver program
Utilities
Utility to calculate hashes for the symbol table
Utility to generate FIRST and FOLLOW set initialisers for the parser
Makefile
Statistics
Statistics for published source files
The Modula-2 Webring
Web sites and web pages related to the Modula-2 programming language.
List all sites | Previous site | Next site | Random site | Join this webring