From 4977bb2d74ad7f91011f5157c4f7b28c90950c05 Mon Sep 17 00:00:00 2001 From: Romain Francois Date: Mon, 10 Sep 2018 10:07:33 +0200 Subject: [PATCH] no need to make ArrayData directly --- r/R/RcppExports.R | 4 ---- r/R/array.R | 4 ---- r/src/RcppExports.cpp | 15 --------------- r/src/array.cpp | 5 ----- 4 files changed, 28 deletions(-) diff --git a/r/R/RcppExports.R b/r/R/RcppExports.R index f3e44dc28ff02..618d462b5cab6 100644 --- a/r/R/RcppExports.R +++ b/r/R/RcppExports.R @@ -1,10 +1,6 @@ # Generated by using Rcpp::compileAttributes() -> do not edit by hand # Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393 -ArrayData_initialize <- function(type, length, null_count, offset) { - .Call(`_arrow_ArrayData_initialize`, type, length, null_count, offset) -} - ArrayData_get_type <- function(x) { .Call(`_arrow_ArrayData_get_type`, x) } diff --git a/r/R/array.R b/r/R/array.R index 0fb3f74f27d82..bfec3f4b2e35a 100644 --- a/r/R/array.R +++ b/r/R/array.R @@ -27,10 +27,6 @@ ) ) -array_data <- function(type, length, null_count = -1, offset = 0){ - `arrow::ArrayData`$new(ArrayData_initialize(type, length, null_count, offset)) -} - `arrow::Array` <- R6Class("arrow::Array", inherit = `arrow::Object`, public = list( diff --git a/r/src/RcppExports.cpp b/r/src/RcppExports.cpp index 4aea5a63f7fbb..405b1b2e912e1 100644 --- a/r/src/RcppExports.cpp +++ b/r/src/RcppExports.cpp @@ -6,20 +6,6 @@ using namespace Rcpp; -// ArrayData_initialize -std::shared_ptr ArrayData_initialize(const std::shared_ptr& type, int length, int null_count, int offset); -RcppExport SEXP _arrow_ArrayData_initialize(SEXP typeSEXP, SEXP lengthSEXP, SEXP null_countSEXP, SEXP offsetSEXP) { -BEGIN_RCPP - Rcpp::RObject rcpp_result_gen; - Rcpp::RNGScope rcpp_rngScope_gen; - Rcpp::traits::input_parameter< const std::shared_ptr& >::type type(typeSEXP); - Rcpp::traits::input_parameter< int >::type length(lengthSEXP); - Rcpp::traits::input_parameter< int >::type null_count(null_countSEXP); - Rcpp::traits::input_parameter< int >::type offset(offsetSEXP); - rcpp_result_gen = Rcpp::wrap(ArrayData_initialize(type, length, null_count, offset)); - return rcpp_result_gen; -END_RCPP -} // ArrayData_get_type std::shared_ptr ArrayData_get_type(const std::shared_ptr& x); RcppExport SEXP _arrow_ArrayData_get_type(SEXP xSEXP) { @@ -861,7 +847,6 @@ END_RCPP } static const R_CallMethodDef CallEntries[] = { - {"_arrow_ArrayData_initialize", (DL_FUNC) &_arrow_ArrayData_initialize, 4}, {"_arrow_ArrayData_get_type", (DL_FUNC) &_arrow_ArrayData_get_type, 1}, {"_arrow_ArrayData_get_length", (DL_FUNC) &_arrow_ArrayData_get_length, 1}, {"_arrow_ArrayData_get_null_count", (DL_FUNC) &_arrow_ArrayData_get_null_count, 1}, diff --git a/r/src/array.cpp b/r/src/array.cpp index 26c257878e6f7..58c3ea29ac7d7 100644 --- a/r/src/array.cpp +++ b/r/src/array.cpp @@ -20,11 +20,6 @@ using namespace Rcpp; // [[Rcpp::plugins(cpp11)]] -// [[Rcpp::export]] -std::shared_ptr ArrayData_initialize(const std::shared_ptr& type, int length, int null_count, int offset){ - return arrow::ArrayData::Make( type, length, {nullptr, nullptr}, null_count, offset); -} - // [[Rcpp::export]] std::shared_ptr ArrayData_get_type(const std::shared_ptr& x){ return x->type;