Hey, I would like to reopen a discussion for uninitialized values in base/types. This was triggered by the following merge request: https://github.com/rock-core/base-types/pull/17
The question boils down to how we want to handle default constructors in base types. Options: a) Leave uninitialized (like e.g. Eigen does) b) Initialize to zero or whatever equivalent c) Initialize to unknown (represented as NaN) I think we currently have a) in some places and c) in others. My contribution to the discussion: b) seems even more dangerous than a, as it wouldn't even be picked up by valgrind. No good. a) May be slightly more efficient in some special cases c) seems like the right thing to do. RigidBodyState tries a mix between a) and c). Maybe this could be the way forward? Cheers, Jakob -- Dr.-Ing. Jakob Schwendner Team Autonomy Besuchsadresse der Nebengeschäftstelle: DFKI GmbH Robotics Innovation Center Robert-Hooke-Straße 5 28359 Bremen, Germany Postadresse der Hauptgeschäftsstelle Standort Bremen: DFKI GmbH Robotics Innovation Center Robert-Hooke-Straße 1 28359 Bremen, Germany Tel.: +49 421 178 45-4120 Zentrale: +49 421 178 45-0 Fax: +49 421 178 45-4150 (Faxe bitte namentlich kennzeichnen) E-Mail: [email protected] Weitere Informationen: http://www.dfki.de/robotik ----------------------------------------------------------------------- Deutsches Forschungszentrum fuer Kuenstliche Intelligenz GmbH Firmensitz: Trippstadter Straße 122, D-67663 Kaiserslautern Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster (Vorsitzender) Dr. Walter Olthoff Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes Amtsgericht Kaiserslautern, HRB 2313 Sitz der Gesellschaft: Kaiserslautern (HRB 2313) USt-Id.Nr.: DE 148646973 Steuernummer: 19/673/0060/3 ----------------------------------------------------------------------- _______________________________________________ Rock-dev mailing list [email protected] http://www.dfki.de/mailman/cgi-bin/listinfo/rock-dev
