Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

wrap_unsafe_function

Wrap “unsafe calls” functions


Description

wrap_unsafe_function declares a function wrapper to a function that causes an R CMD check NOTE when called directly. We should usually not call these functions, but we need some of them because we want to explicitly support features they provide.

Usage

wrap_unsafe_function(ns, name)

Arguments

ns

The namespace of the unsafe function.

name

The name of the unsafe function.

Value

wrap_unsafe_calls returns a wrapper function with the same argument as the wrapped function that can be called without causing a NOTE.

Note

Using an implementation that simply aliases getExportedValue does not work, since R CMD check sees right through this “ruse”.


box

Write Reusable, Composable and Modular R Code

v1.0.2
MIT + file LICENSE
Authors
Konrad Rudolph [aut, cre] (<https://orcid.org/0000-0002-9866-7051>), Michael Schubert [ctb] (<https://orcid.org/0000-0002-6862-5221>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.