MCPcopy Create free account
hub / github.com/RcppCore/Rcpp / get_rcpp_cache

Function get_rcpp_cache

src/barrier.cpp:140–156  ·  view source on GitHub ↗

only used for debugging

Source from the content-addressed store, hash-verified

138
139// only used for debugging
140SEXP get_rcpp_cache() {
141 if (! Rcpp_cache_know) {
142
143 SEXP getNamespaceSym = Rf_install("getNamespace"); // cannot be gc()'ed once in symbol table
144 Rcpp::Shield<SEXP> RcppString(Rf_mkString("Rcpp"));
145 Rcpp::Shield<SEXP> call(Rf_lang2(getNamespaceSym, RcppString));
146 Rcpp::Shield<SEXP> RCPP(Rf_eval(call, R_GlobalEnv));
147
148#if R_VERSION < R_Version(4,5,0)
149 Rcpp_cache = Rf_findVarInFrame(RCPP, Rf_install(".rcpp_cache"));
150#else
151 Rcpp_cache = R_getVar(Rf_install(".rcpp_cache"), RCPP, TRUE);
152#endif
153 Rcpp_cache_know = true;
154 }
155 return Rcpp_cache;
156}
157
158namespace Rcpp {
159 namespace internal {

Callers 8

get_Rcpp_namespaceFunction · 0.85
rcpp_get_stack_traceFunction · 0.85
rcpp_set_stack_traceFunction · 0.85
reset_current_errorFunction · 0.85
error_occuredFunction · 0.85
rcpp_error_recorderFunction · 0.85
rcpp_get_current_errorFunction · 0.85
get_cacheFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected