orocos-toolchain / rtt

Orocos Real-Time Toolkit
http://www.orocos.org
Other
72 stars 79 forks source link

Fix compiler warnings with GCC 9 (with API changes) #317

Closed meyerj closed 4 years ago

meyerj commented 4 years ago

This pull request eliminates some compiler warnings with newer compilers (GCC 9 in upcoming Ubuntu 20.04, with Boost 1.72). Some warnings are older and already appeared before.

The patch also includes an API update proposal for more consistent copy assignment semantics of RTT::Property<T>, which was inconsistent with copy construction, and a slightly modified API of RTT::PropertyBag for adding properties, that likely has no effect in practice.

snrkiwi commented 4 years ago

LGTM

meyerj commented 4 years ago

I am not so sure yet about the new assignment semantics of RTT::Property<T>. I was actually surprised that copy construction and copy assignment had different semantics, but I think it is more consistent like it is now:

On the other hand some existing code might depend on the old semantics. RTT unit tests still pass successfully.

snrkiwi commented 4 years ago

Probably best we can do. The inconsistencies in application will have to be dealt with ... :-(

meyerj commented 4 years ago

RTT::Attribute also has the same, more consistent semantics:

So I start to think that it was actually a bug.