Creates a new function without any arguments that captures the provided variables.
Arguments
- ...
(
FuncVariable)
The variables to capture.
Value
(list() of FuncVariable)
Examples
func <- local_func()
x <- hlo_input("x", "f32", shape = c(2, 2))
#> Error in .current_func(): No function is currently being built
y <- hlo_input("y", "f32", shape = c(2, 2))
#> Error in .current_func(): No function is currently being built
f <- hlo_closure(x, y)
#> Error: object 'x' not found
print(f)
#> Error: object 'f' not found