Skip to content

Commit

Permalink
if an expression was cached, we and is to ignore, we must also keep i…
Browse files Browse the repository at this point in the history
…t in stylerignore because the parse table will be shallow
  • Loading branch information
lorenzwalthert committed Feb 22, 2020
1 parent 8372af2 commit fd6dfff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/stylerignore.R
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ env_add_stylerignore <- function(pd_flat) {
unlist()
pd_flat_temp$lag_newlines <- pd_flat_temp$lag_newlines
pd_flat_temp$lag_spaces <- lag(pd_flat_temp$spaces, default = 0)
is_terminal_to_ignore <- pd_flat_temp$terminal & pd_flat_temp$stylerignore
env_current$stylerignore <- pd_flat_temp[is_terminal_to_ignore, ]
is_to_ignore <- (pd_flat_temp$terminal | pd_flat_temp$is_cached) & pd_flat_temp$stylerignore
env_current$stylerignore <- pd_flat_temp[is_to_ignore, ]
}

#' Adds the stylerignore column
Expand Down

0 comments on commit fd6dfff

Please sign in to comment.