document() appears to emit an export() line for ANY function that carries a roxygen block - @noRd suppresses the .Rd file as expected, but not the NAMESPACE export, and a leading-dot name doesn't prevent it either.
Repro:
#' Internal helper
#' @param x thing
#' @noRd
.my_helper <- function(x) x
After tinyrox::document(), NAMESPACE contains export(.my_helper). Expected: no export (roxygen2 semantics - export only on explicit @export).
Impact: internal helpers silently become public API surface, which matters right before a CRAN submission (found in chatterbox: a private chunking helper got exported; current workaround is demoting internal docs to plain # comments, which loses the structured documentation).
Related: #17 (useDynLib). Both are 'document() rewrites NAMESPACE more aggressively than the tags imply' class.
document() appears to emit an
export()line for ANY function that carries a roxygen block -@noRdsuppresses the .Rd file as expected, but not the NAMESPACE export, and a leading-dot name doesn't prevent it either.Repro:
After
tinyrox::document(), NAMESPACE containsexport(.my_helper). Expected: no export (roxygen2 semantics - export only on explicit@export).Impact: internal helpers silently become public API surface, which matters right before a CRAN submission (found in chatterbox: a private chunking helper got exported; current workaround is demoting internal docs to plain
#comments, which loses the structured documentation).Related: #17 (useDynLib). Both are 'document() rewrites NAMESPACE more aggressively than the tags imply' class.