gen <- odin.dust::odin_dust({
len <- user(integer = TRUE)
mean <- user(0)
sd <- user(1)
x[] <- rnorm(mean, sd)
initial(z) <- 0
update(z) <- z + sum(x)
dim(x) <- len
}, verbose = TRUE)
with
dust.cpp: In member function ‘void odin::update(size_t, const real_t*, dust::rng_state_t<double>&, odin::real_t*)’:
dust.cpp:42:25: error: ‘odin_sum1’ was not declared in this scope
42 | state_next[0] = z + odin_sum1(internal.x.data(), 0, shared->dim_x);
| ^~~~~~~~~
make: *** [/usr/lib/R/etc/Makeconf:181: dust.o] Error 1
ERROR: compilation failed for package ‘odin4d615a16’
This fails:
with
we're not including odin_sum1 somehow