[eigen] Const referencing of matrix indexes

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]

I just noticed the matrixbase operator[](int index) const (and
operator()(...) const) both return "const Scaler" rather than "const
Scaler&". Just out of curiosity, what is the reasoning behind this?
I've always thought it was standard practice (reading from e.g. the
c++ faq-lite) and faster for large objects to return the const


Phone : +82-10-5400-3296 (010-5400-3296)
Home: http://snorriheim.dnsdojo.com/
Yujin Robot: http://www.yujinrobot.com/
Embedded Control Libraries: http://snorriheim.dnsdojo.com/redmine/wiki/ecl

Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/