Generation of compon... Theses on offer Model based generati...

Diploma thesis

Restrictions of Programming Languages

(Original Title:Einschränkungen von Programmiersprachen)



In order to make programming languages more suitable for use in high integrity, safety critical software, it is necessary to make restrictions on them. Restrictions on the languages remove features that would compromise the integrity of the software on which the languages are used. Removing unsafe constructs from a language, results in a subsets of the languages from which the restrictions are made. Such subsets are called safe subsets. Besides imposing restrictions there are attempts to make the languages more suitable for the development of safety critical software by making extensions to them.

In this work the subsets of of C, C++ and Ada were identified and the the following aspects examined:

  1. Restrictions
  2. Extensions
  3. Shortcomings
  4. user base

Among the subsets of C, MISRA C is the most suitable subset for the development of safety critical software because it has the highest number of Restrictions and no extensions on the one hand and has the highest Tool support on the other hand.
Ada does not have many subsets. For programming sequential programs with only one process, SPARK is most suitable for use. For programming software with concurrent processes and time critical software, RAVEN should be used.
For C++ only one subset was identified. The restrictions of this subset are directed towards making C++ more suitable for use in embedded consumer devices.

The tools used to support each subset were also examined and as far as possible compared with each other. Tool of the subsets are for example static analysers and compilers.

The Java programming language was also looked at with respect to the constructs that make Java less suitable for programming safety critical software. Six pitfalls of Java were selected and based on them six restricting rules were established order to derive a safe subset of Java based on the restrictions.

Based on the established rules, a static tool was developed to check that any given Java data keeps the rules established.

Author: Bernard Kiiru

Tutor: Dipl.-Math. Jens Palluch