Skip to content
Prev 5586 / 10988 Next

[Rcpp-devel] Datetime substraction bug ?

Thanks,
agreed, "bug" can be replaced by "feature" here, though a surprisingly
strange one as I never encountered such in any dateTime class.
Good news is that operator < is implemented as I thought

   - bool operator<<http://dirk.eddelbuettel.com/code/rcpp/html/namespaceRcpp.html#adf2a70049435b345d5d049c3ab00658b>
   (const Datetime<http://dirk.eddelbuettel.com/code/rcpp/html/classRcpp_1_1Datetime.html>&d1,
   const Datetime<http://dirk.eddelbuettel.com/code/rcpp/html/classRcpp_1_1Datetime.html>&
   d2) { return
d1.m_dt<http://dirk.eddelbuettel.com/code/rcpp/html/classRcpp_1_1Datetime.html#a0655024a342ad356a28b3a58d4886956><
d2.
   m_dt<http://dirk.eddelbuettel.com/code/rcpp/html/classRcpp_1_1Datetime.html#a0655024a342ad356a28b3a58d4886956>;
   }

It teaches a lesson: always go and check the sources (unless you are
looking at a commutative operator ;))

2013/3/31 Robin Girard <robin.girard at mines-paristech.fr>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20130331/a2dd03c4/attachment.html>