Hello Dirk, <br>no excitement at all, very simple it is.<br>We were 
merely pinpointing that this definition of "operator -" was very 
unintuitive, but hey, you wrote the code, your right to put it the way 
you want, I am very happy to have have the right to use it for free.<br>
<br>Cheers<br><br><div class="gmail_quote">2013/3/31 Dirk Eddelbuettel <span dir="ltr"><<a href="mailto:edd@debian.org" target="_blank">edd@debian.org</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
I don't really understand all the excitement here.<br>
<br>
It's quick enough to define a function to do what you want, no?<br>
<br>
R> NewYear <- as.Date("2013-01-01")<br>
R> Easter <- Sys.Date()<br>
R> cppFunction('double ddiff(Date a, Date b) { return a - b; }')<br>
R> cppFunction('double ddiff2(Date a, Date b) { return b - a; }')<br>
R> ddiff(NewYear, Easter)<br>
[1] 89                            ## I find this more logical<br>
R> ddiff2(NewYear, Easter)<br>
[1] -89                           ## closer to R's difftime and 'odd' to me<br>
R><br>
<span class="HOEnZb"><font color="#888888"><br>
Dirk<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
--<br>
Dirk Eddelbuettel | <a href="mailto:edd@debian.org">edd@debian.org</a> | <a href="http://dirk.eddelbuettel.com" target="_blank">http://dirk.eddelbuettel.com</a><br>
</div></div></blockquote></div><br>