Generating Software from Specifications WS 2013/14 - Assignment 10
Published: January 08, 2014 -- Turn in until January 15 at 12h
What to turn in: see Assignment 1
Exercise 27 (Use PTG to change the target language)
In the directory blatt10/struct
you will find a specification
file StructToCplpl.fw
.
It specifies a structure generator according to the
example in the lecture material and in the GSS book. It translates
descriptions of structures into C++. Your task is to modify the translation
such that a Java file is generated.
It is recommended first to take an output file in C++ and rewrite it manually into a compilable Java file. Then analyze and modify the PTG patterns (and their calls if necessary) until the processor translates correctly into Java. Test your processor carefully.
Exercise 28 (Project: Specification of semantic analysis)
Work on your project and develop the specification of the semantic analysis phase. Make sure that you have completely designed the semantic analysis phase according to Exercise 25. Then elaborate the following steps to specify the semantic analysis:
- Specify name analysis for your DSL, if needed. Use the
name analysis modules of Eli's library, as described in Chapters
4, 5, an 7 of the lecture material.
Consult Eli's documentation as far as necessary.
Write suitable explanations along with your specifications.
Test the results of your specification so far on your test suite.
- Consider the set of violations you collected in Exercise 25,
and decompose it into subsets of violations that refer to the
same topic or use the same information to be checked.
Then implement each subset by propagation and checking of
information, and issuing suitable error messages.
Write suitable explanations along with your specifications.
Test the results of your specification so far on your test suite.
- Develop some correct, real life programs in your DSL which will finally be used to demonstrate your language design and implementation.
Do not forget to take notes on what you did, what you learned, and which problems you encountered, and turn them in.
Generiert mit Camelot | Probleme mit Camelot? | Geändert am: 15.01.2014