R/zzz.R

# nocov start
.onLoad <- function (libname, pkgname) { # nolint

    options ("typetracedir" = tempdir ())

}

.onUnload <- function (libname, pkgname) { # nolint

    options ("typetracedir" = NULL)
    options ("typetrace_trace_lists" = NULL)
    f <- file.path (tempdir (), "fn_bodies")
    if (dir.exists (f)) {
        unlink (f, recursive = TRUE)
    }
}
# nocov end

Try the typetracer package in your browser

Any scripts or data that you put into this service are public.

typetracer documentation built on July 9, 2023, 7:40 p.m.