Skip to content

Commit

Permalink
Use deparse1() instead of paste(deparse(), collapse = " "). Fixes #2709.
Browse files Browse the repository at this point in the history
  • Loading branch information
jplecavalier committed Aug 15, 2024
1 parent be2fd26 commit 22f2364
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/rd-example.R
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ process_conditional_examples <- function(rd) {
if (isTRUE(cond)) {
remove <- c(remove, idx, idx + 1L)
} else {
cond_expr_str <- paste(deparse(cond_expr), collapse = " ")
cond_expr_str <- deparse1(cond_expr)
is_false <- cond_expr_str == "FALSE"
if (!is_false) {
new_cond <- paste0("if (FALSE) { # ", cond_expr_str)
Expand Down

0 comments on commit 22f2364

Please sign in to comment.