Skip to content

Commit

Permalink
Update cpp11.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
jayhesselberth committed Jan 21, 2025
1 parent 5d5b31f commit 93ecbe1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/cpp11.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ using namespace Rcpp;
#include <R_ext/Visibility.h>

// random.cpp
writable::data_frame random_impl(data_frame genome, int length, int n, int seed);
writable::data_frame random_impl(data_frame genome, double length, int n, int seed);
extern "C" SEXP _valr_random_impl(SEXP genome, SEXP length, SEXP n, SEXP seed) {
BEGIN_CPP11
return cpp11::as_sexp(random_impl(cpp11::as_cpp<cpp11::decay_t<data_frame>>(genome), cpp11::as_cpp<cpp11::decay_t<int>>(length), cpp11::as_cpp<cpp11::decay_t<int>>(n), cpp11::as_cpp<cpp11::decay_t<int>>(seed)));
return cpp11::as_sexp(random_impl(cpp11::as_cpp<cpp11::decay_t<data_frame>>(genome), cpp11::as_cpp<cpp11::decay_t<double>>(length), cpp11::as_cpp<cpp11::decay_t<int>>(n), cpp11::as_cpp<cpp11::decay_t<int>>(seed)));
END_CPP11
}

Expand Down

0 comments on commit 93ecbe1

Please sign in to comment.