library(inline)
library(Rcpp)
body<-'      
       a[3]=(1,2,3);
       b[4]=(6,7,8,0);
       xlist=Rcpp::List::create(a,b); 
       return xlist;  
      '
fx<-cxxfunction(signature(), plugin='Rcpp', body)  
a<-fx()
a
is.list(a)
想用c语言生成一个list并返回,结果这样:
Warning message:
运行命令'make -f "C:/PROGRA~1/R/R-32~1.2/etc/i386/Makeconf" -f "C:/PROGRA~1/R/R-32~1.2/share/make/winshlib.mk" SHLIB_LDFLAGS='$(SHLIB_CXXLDFLAGS)' SHLIB_LD='$(SHLIB_CXXLD)' SHLIB="file22bc7f70604a.dll" OBJECTS="file22bc7f70604a.o"'的状态是127 
ERROR(s) during compilation: source code errors or compiler configuration errors!
想问原因