The project consists of the development of an interpreter for a subset of the SCL language

computer science

Description

The project consists of the development of an interpreter for a subset of the SCL language. The interpreter can be implemented in any of the following programming languages: C,C++,Java, Python.

The language processor will process an SCL program. All tokens in this language are separated by white spaces. The parsing algorithm should detect any syntactical error. Each error discovered should cause an appropriate error message to be printed. Run-time errors should also be detected with appropriate error messages being printed.

 In your implementation, the source code (of the Scanner, Parser, and Complete Interpreter):

·       The source code must be well-structured and be easy to understand, comments should help in clarifying your implementation.

·       Do not 'hard-code' input data in your source programs, use appropriate input statements. Otherwise, it beats the purpose of software development.

Your complete submission must include: a well written report , the subset of the SCL grammar used (in BNF or EBNF notation), source code files of the implementation, input SCL program file used to test your project.

Your report must document the work done. Include explanation of how to run your program, the input and the output produced when running your program.

 

* For Scanner:

    Develop a complete scanner for the subset of the SCL language (in .exe file) . The scanner implementation must include an array of the keywords used in the subset of SCL, an array (or list) of the identifiers.

Define the grammar of a subset of SCL (in BNF or EBNF notation). You must submit a short report describing the work performed. You must also include the grammar of the subset of SCL, source code files of the scanner program, the input and output files. The report must show the execution of this scanner program by using appropriate input files, the program must show a list of the tokens scanned.


* For Parser:

      Develop a complete parser for the subset of the SCL language (in .exe file). This parser program must execute with the scanner. The report must show the execution of this parser program by using one or more relevant input files, the program must show the corresponding statements recognized. The  report must describe the work performed. Include the parser source program, input and output files.

 

* For Complete Intepreter:

  Develop a complete interpreter or a translator to intermediate code and an abstract machine. that includes the scanner, parser, and executer. The report  must show the execution of this interpreter program by using one or more input files, the program must show the results of executing every statement recognized by the parser. Write a report describing the work performed. Include the source code of the program, input and output files.

 

Instruction Files

Related Questions in computer science category