如何在C++中使用RCPP_MODULE(yada)。 我的C++程序给出错误,如果我使用R/C++接口
const char* hello(std::string who){
std::string result("hello ") ;
result += who ;
return result.c_str() ;
}
RCPP_MODULE(yada)
{
using namespace std;
function("hello", &hello) ;
};
错误是:
1.错误1错误C2065:矢田':未声明的标识符
2.错误2错误C2448: 'RCPP_MODULE':函数式初始化器似乎是一个函数定义
任何人都可以帮助我解决这些错误?
什么是RCPP_MODULE?我应该知道吗? – sbi 2010-07-19 14:06:51
我认为这是一个“R到CPP”的事情。 http://dirk.eddelbuettel.com/code/rcpp.html – Roddy 2010-07-19 14:44:57
交叉发布:http://www.wilmott.com/messageview.cfm?catid=10&threadid=78305 – Shane 2010-07-20 11:25:44