Skip to content

Commit

Permalink
let eval = 1, 2, 3 instead of 0, 1, 2, since eval=0 sounds like eval=…
Browse files Browse the repository at this point in the history
…FALSE
  • Loading branch information
yihui committed Jul 5, 2024
1 parent 1b44c78 commit 875edad
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/fuse.R
Original file line number Diff line number Diff line change
Expand Up @@ -909,8 +909,8 @@ eng_r = function(x, inline = FALSE, ...) {
hash = opts$cache.hash, extra = opts$cache.extra, keep = opts$cache.keep,
id = opts$label, rw = opts$cache.rw
)
# support eval = 0, 1, 2 (pass to the 'verbose' argument of record())
if (is.numeric(opts$eval)) args$verbose = opts$eval
# support eval = 1, 2, 3 (pass to the 'verbose' argument of record())
if (is.numeric(opts$eval)) args$verbose = opts$eval - 1
do.call(xfun::record, c(list(code = x$source, envir = fuse_env()), args))
}

Expand Down

0 comments on commit 875edad

Please sign in to comment.