tests/length.R

library(RLLVMCompile)
f = function(x)  length(x) 
fc = compileFunction(f, Int32Type, REALSXPType, name = "f")

x = rnorm(10)
stopifnot(identical(.llvm(fc, x), length(x)))
duncantl/RLLVMCompile documentation built on May 15, 2019, 5:31 p.m.