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
C++11 trailing return types not supported for exported functions #727
Comments
Good find. We're unlikely to fix this though as we have an ad-hoc parser for C++ that was developed some years ago. Modifying it for this alternate way of expressing return types carries cost and risk that IMO aren't warranted. One related undertaking we've considered is to allow parsing to optionally use libclang (when available). That's not on the short term roadmap but would also remedy this issue. |
I suspected as much from the error message. 👍 for libclang support, in the long run. |
Any plans for implementing this? |
No, I think that was addressed in the comments above from 2017 (indicating likely side effects to a core functionality) so I should probably just close this. Or do you have any new insights to share? |
This issue is stale (365 days without activity) and will be closed in 31 days unless new activity is seen. Please feel free to re-open it is still a concern, possibly with additional data. |
When using C++11 trailing return types on a function marked with
[[Rcpp::export]]
, compilartion fails. Trailing return types work for non-exported functions.Here’s an MWE (
rcpptest.cpp
):By changing the definition of
test
(but notimpl
!) to use conventional return types, the code compiles:The text was updated successfully, but these errors were encountered: