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

Function takeLogRcppLocation

inst/tinytest/cpp/exceptions.cpp:50–55  ·  view source on GitHub ↗

[[Rcpp::export]]

Source from the content-addressed store, hash-verified

48
49// [[Rcpp::export]]
50double takeLogRcppLocation(double val) {
51 if (val <= 0.0) {
52 throw Rcpp::exception("Inadmissible value", "exceptions.cpp", 44);
53 }
54 return log(val);
55}
56
57double f1(double val) {
58 return takeLogRcppLocation(val);

Callers 1

f1Function · 0.85

Calls 2

exceptionClass · 0.85
logFunction · 0.50

Tested by

no test coverage detected