You will deliver each stage of your project in the form of a code repository. The repository is a directory that contains all of the code and documents you create for the project.
This page describes a standard set of files for the project directory and a standard way to organize the directory. Please manage your project directory in a similar fashion over the course of the semester. If you would like to deviate in a significant way, please run your ideas by me.
Your project directory should contain the following items at the top level.
A plaintext README file provides basic information about your project to the reader. It should begin with these sections, in this order:
The README may also explains the top-level architecture of your compiler and any design decisions that you think will help the reader understand your program better. It can point to more detailed documentation in the doc/ directory (see below).
- the team name and the names of all team members
- a basic description of project, including
- a list of known bugs
- a list of any languages features not implemented in your compiler
- a description of any optimizations you implemented
- a description of how to build your compiler, if necessary, showing the steps to compile and link the source code of your submission. Preferred solutions include a simple make file or a build shell script of your own creation.
- a description of how to run the various components of your compiler, using the names of the Unix scripts included in the submission (see below)
Over the course of the project, you will create five scripts that make up the command-line suite of your compiler: flairs, flairf, flairp, flairv, and flairc. Add each script at the corresponding point of the project, as assigned.
The src/ directory contains all of the source files that implement your compiler. This includes:
Be sure to clean up this directory before you submit a deliverable. Stray *.class, *.java~, and __pycache__ files distract the reader and exhibit a lack of care.
- the code for the various modules (scanner, parser, etc.)
- the various data structures used by the modules (tokens, AST nodes, etc.)
- the drivers for the various modules (tokenizer, AST printer, etc.)
The doc/ directory contains all of the files that document your work, including:
These files can be plaintext, PDF, or image files.
- any old versions of your README file, either numbered by project module or integrated into a single document
- the full language grammar from the project page
- the refactored grammar you used to build your parse table
- any data files that document your deisgn, including the regular expressions and finite-state automata for tokens, the parse table, and the memory layout of youe run-time system
- any other design documents, images, etc. that you have created
The programs/ directory contains any legal programs written in the source language. The most important of these are the programs your team writes for the various project modules. The directory may also contain source programs you write for your own use and source programs provided in the directory linked from the project web page.
The tests/ directory contains the all of the code you create to test your compiler. This might include:
- unit tests written in your implementation language that work within an automated test framework
- source files you create to test your compiler, such as files containing lexical, syntactic, and semantic errors
If you create any other files as a part of your project that do not fit in one of the directories described above, put them in a misc/ directory.