File tree 2 files changed +12
-4
lines changed
tests/testthat/unindention
2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -231,13 +231,14 @@ remove_line_break_before_round_closing_after_curly <- function(pd) {
231
231
232
232
remove_line_breaks_in_fun_dec <- function (pd ) {
233
233
if (is_function_declaration(pd )) {
234
+ is_double_indention <- is_double_indent_function_declaration(pd )
234
235
round_after <- (
235
236
pd $ token == " ')'" | pd $ token_before == " '('"
236
237
) &
237
238
pd $ token_before != " COMMENT"
238
239
pd $ lag_newlines [pd $ lag_newlines > 1L ] <- 1L
239
240
pd $ lag_newlines [round_after ] <- 0L
240
- if (is_double_indent_function_declaration( pd ) ) {
241
+ if (is_double_indention ) {
241
242
pd $ lag_newlines [lag(pd $ token == " '('" )] <- 1L
242
243
}
243
244
}
Original file line number Diff line number Diff line change @@ -58,7 +58,8 @@ function(
58
58
}
59
59
60
60
61
- function (x , y ) {
61
+ function (
62
+ x , y ) {
62
63
1
63
64
}
64
65
@@ -70,9 +71,15 @@ function(x,
70
71
71
72
72
73
# last brace
73
- function (x , y ) NULL
74
+ function (
75
+ x , y ) {
76
+ NULL
77
+ }
74
78
75
- function (x , y ) NULL
79
+ function (
80
+ x , y ) {
81
+ NULL
82
+ }
76
83
77
84
function (
78
85
x ,
You can’t perform that action at this time.
0 commit comments