tests2/onePlus.R

library(R2llvm)
f = function() 1L + 2L

#R2llvm recognizes this as a constant.

#debug(compileFunction)
fc = compileFunction(f, optimize = FALSE)
identical(.llvm(fc), 3L)
duncantl/R2llvm documentation built on May 14, 2019, 9:42 a.m.