TY - THES A1 - Graf von Perponcher-Sedlnitzki, Philipp Christian T1 - Comparison of Rust to Ada and C in regards to safety-related software N2 - The goal of this thesis is to give a basic understanding whether Rust can be suited for safety-critical systems programming projects where Ada is currently the mainly present language. To get an overview over the features that make these languages suitable for safe programming, several common programming errors and the languages' reaction to them will be looked at. For this comparison part, C is added to get an understanding of how a programming language that is not targeted at safety handles these errors. The outcome from these tests were that Rust covers all safety features that Ada has, even offering additional ways of dealing with certain errors. It also enforces stricter rules in some places, for example when dealing with concurrent programs and shared resources. Apart from the technological background, the programming environment is also important for a language to be suitable for bigger projects. From an official side, Ada has a big advantage due to its long history and firm foothold in the aerospace industry while Rust is open-source and does currently not have any kind of certification for its safety features. Another part of the environment is the developers themselves, where Rust has a clear advantage due to its fairly young age and a strong online community and popularity. The question whether Rust can be suited for safety-critical projects or even be a valid alternative to Ada in that regard can't really be answered with a clear Yes or No. In case any official guidelines that require some sort of certification have to be adhered to, Rust may be a little difficult to use as it does not have any, even though efforts in that direction are well on the way. If no guidelines have to be followed, Rust can definitely be a realistic alternative to Ada due to its popularity while still offering very safe programming. Y1 - 2022 UR - http://nbn-resolving.de/urn/resolver.pl?urn:nbn:de:bvb:573-33834 CY - Ingolstadt ER - TY - THES A1 - Graf von Perponcher-Sedlnitzki, Philipp Christian T1 - Integrating the future into the past BT - Approach to seamlessly integrate newly-developed Rust-components into an existing C++-system N2 - The goal of this thesis is to provide a guide that can be used by software developers that wants to include Rust into an existing C++ application. After a brief summary of the languages, both the basics of integrating Rust code into C++ applications and the reverse way are presented to set a common base of knowledge. Additionally, a few tools and libraries are introduced, namely bindgen, cbindgen, cxx, and the cc crate. As they are being used in the following guide, the toolsets CMake and CMakeRust are presented and explained in more detail to make it easier for developers to include and use them in their own projects. The guide is separated into three steps which help to identify the required interfaces, implement them and eventually include everything into the C++ compilation process. Apart from more advanced types based on pointers, the integration is fairly easy and straight-forward. Using structs and their implemented methods, Rust is able to replicate a class structure that is typical for object-oriented C++. After providing the required binding files, the Rust component can easily be called from C++ code like any other function. While external Rust methods need to be called using a function(Object) syntax, they can be also be converted and used via the standard Object.function() syntax by implementing wrapper classes that translate the calls. These can then be included in more complex C++ architectures like inheritance structures. The usage of the aforementioned advanced types, which are based on pointers, is not covered in this thesis, though the cxx library can be used for those. The compilation for and usage on embedded targets is also possible with its required effort depending on the target architecture. If the necessary target is not officially supported yet, some additional things like the standard library need to be downloaded and compiled manually. The thesis comes to the conclusion that considering C++ is not officially supported by the Rust FFI, it works very well with the C ABI and apart from one floating point type, no clear limitations or incompatibilities were identified. For interfaces that only work with basic types and to get a general understanding of the topic, this thesis is a good starting point and guide for a developer who is new to the topic. Y1 - 2024 UR - http://nbn-resolving.de/urn/resolver.pl?urn:nbn:de:bvb:573-45429 CY - Ingolstadt ER -