support warn_conflicts
Showing 1 of 8 files from the diff.
Other files ignored by Codecov
man/highlight.Rd
has changed.
DESCRIPTION
has changed.
NAMESPACE
has changed.
man/default_style.Rd
has changed.
man/print.function.Rd
has changed.
man/color_brackets.Rd
has changed.
man/prettycode.Rd
has changed.
@@ -5,14 +5,16 @@
Loading
5 | 5 | #' syntax highlighting, using ANSI colors, if the terminal supports them. |
|
6 | 6 | #' |
|
7 | 7 | #' @export |
|
8 | + | #' @param warn_conflicts logical. If \code{TRUE}, warnings are printed |
|
9 | + | #' about conflicts from replacing the standard print method. |
|
8 | 10 | ||
9 | - | prettycode <- function() { |
|
11 | + | prettycode <- function(warn_conflicts = TRUE) { |
|
10 | 12 | register_s3_method("prettycode", "print", "function", print.function) |
|
11 | 13 | if (! obj_name %in% search()) { |
|
12 | 14 | env <- new.env(parent = emptyenv()) |
|
13 | 15 | env$print.function <- print.function |
|
14 | 16 | env$`!` <- exclam |
|
15 | - | do.call("attach", list(env, name = obj_name)) |
|
17 | + | do.call("attach", list(env, name = obj_name, warn.conflicts = warn_conflicts)) |
|
16 | 18 | } |
|
17 | 19 | } |
|
18 | 20 |
Files | Coverage |
---|---|
R | 76.13% |
Project Totals (6 files) | 76.13% |
Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file.
The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files.
The size and color of each slice is representing the number of statements and the coverage, respectively.