-
-
Notifications
You must be signed in to change notification settings - Fork 208
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Signed/unsigned comparison in IndexHash #1152
Comments
( Not fully complete reproducible example as you did not include a trivial call to |
Oh but to reproduce the "warning" no call to the function itself should be necessary. I am getting it when I compile through |
(I understand that. I already reproduced it. I still ask you to add an example call so that everybody has the same run-time experience.) I assume you are also aware of how to add flags such as |
Of course, thank you however. I mostly placed this report as it seemed to be a regression from the #574 (which was apparently fixed?). In practice it is only a nuisance. |
Which is why it is not worth a) filing an issue (it is merely a warning) but if one insists as you do it is double foolish to do 95% of the work of an MCVE only to fail to add a call. But the worst is then to argue with me here 😁 instead of just saying "ah, yes" and editing the post. |
You can carry the one-line fix over from 6a9ecc1. (That comment was left pending for a few hours.) |
What I meant with callable example was that you did already really well with the C++ snippet above, Just add this at the end /*** R
x <- 1:6
table <- 1:20
testStuff(x, table)
*/ which then gets autocalled when you library(Rcpp)
sourceCpp(...) which is really |
True, I didn't think of inlining the code into the Cpp snippet. I don't really use that feature day to day. 😀 And thanks for the quick fix. I've cloned it, as I'm likely doomed to forget setting the flags once in a while (and I prefer to stay out of Makeconf). 😁 |
Don't. It is useful, and documented in Writing R Extensions. We only have a small number of hooks. This is a potent one. |
This is a reboot of an old issue from 2016 #574, that seems to be present once again while compiling under windows. The compiler throws a warning after compiling the below code. Assume the below minimum reproducible example is located in the working directory in a file called test.cpp. Calling
sourceCpp("test.cpp")
results in a warning.Snippet from the warning:
Session info included at the very bottom.
The text was updated successfully, but these errors were encountered: