orocos-toolchain / orogen

Code generator for components and type handling in Rock - the Robot Construction Kit - and the Orocos Toolchain
http://rock-robotics.org
Other
4 stars 35 forks source link

gen: implement Typekit#remove_types #142

Closed doudou closed 3 years ago

doudou commented 3 years ago

The current implementation of type_export_policy only deals with type exports, i.e. the RTT side of things. All types within the imported headers are still processed, saved in the tlb files and conversion methods (to e.g. CORBA) are generated for them. This is so as the RTT side is the one that is really heavy in compilation time and binary size.

However, there are some cases where types may be incompatible with the conversion. For instance, CORBA forbids any identifier to match a keyword. It's easy to modify when one controls said header, but if (1) we don't control the header and (2) the header contains both the offending type and types that are needed, we ended up in a broken situation.

This new method allows to explicitly remove the problematic type(s) even if they were imported.