@@ -76,13 +76,13 @@ tidyverse_style <- function(scope = "tokens",
76
76
indention_manipulators <- if (" indention" %in% scope ) {
77
77
list (
78
78
indent_braces = partial(indent_braces , indent_by = indent_by ),
79
- unindent_fun_dec = unindent_fun_dec ,
79
+ unindent_function_declaration = unindent_function_declaration ,
80
80
indent_op = partial(indent_op , indent_by = indent_by ),
81
81
indent_eq_sub = partial(indent_eq_sub , indent_by = indent_by ),
82
82
indent_without_paren = partial(indent_without_paren ,
83
83
indent_by = indent_by
84
84
),
85
- update_indention_ref_fun_dec = update_indention_ref_fun_dec
85
+ update_indention_reference_function_declaration = update_indention_reference_function_declaration
86
86
)
87
87
}
88
88
space_manipulators <- if (" spaces" %in% scope ) {
@@ -102,19 +102,19 @@ tidyverse_style <- function(scope = "tokens",
102
102
style_space_around_tilde ,
103
103
strict = strict
104
104
),
105
- spacing_around_op = purrr :: partial(set_space_around_op ,
105
+ spacing_around_op = purrr :: partial(set_space_around_operator ,
106
106
strict = strict
107
107
),
108
108
remove_space_after_opening_paren = remove_space_after_opening_paren ,
109
109
remove_space_after_excl = remove_space_after_excl ,
110
110
set_space_after_bang_bang = set_space_after_bang_bang ,
111
111
remove_space_around_dollar = remove_space_around_dollar ,
112
- remove_space_after_fun_dec = remove_space_after_fun_dec ,
112
+ remove_space_after_function_declaration = remove_space_after_function_declaration ,
113
113
remove_space_around_colons = remove_space_around_colons ,
114
114
start_comments_with_space = partial(start_comments_with_space ,
115
115
force_one = start_comments_with_one_space
116
116
),
117
- remove_space_after_unary_pm_nested = remove_space_after_unary_pm_nested ,
117
+ remove_space_after_unary_plus_minus_nested = remove_space_after_unary_plus_minus_nested ,
118
118
spacing_before_comments = if (strict ) {
119
119
set_space_before_comments
120
120
} else {
@@ -137,8 +137,8 @@ tidyverse_style <- function(scope = "tokens",
137
137
set_line_break_before_curly_opening = set_line_break_before_curly_opening ,
138
138
remove_line_break_before_round_closing_after_curly =
139
139
if (strict ) remove_line_break_before_round_closing_after_curly ,
140
- remove_line_breaks_in_fun_dec =
141
- if (strict ) remove_line_breaks_in_fun_dec ,
140
+ remove_line_breaks_in_function_declaration =
141
+ if (strict ) remove_line_breaks_in_function_declaration ,
142
142
set_line_breaks_between_top_level_exprs =
143
143
if (strict ) set_line_breaks_between_top_level_exprs ,
144
144
style_line_break_around_curly = partial(
@@ -180,10 +180,10 @@ tidyverse_style <- function(scope = "tokens",
180
180
force_assignment_op = force_assignment_op ,
181
181
resolve_semicolon = resolve_semicolon ,
182
182
add_brackets_in_pipe = add_brackets_in_pipe ,
183
- wrap_if_else_while_for_fun_multi_line_in_curly =
183
+ wrap_if_else_while_for_function_multi_line_in_curly =
184
184
if (strict ) {
185
185
purrr :: partial(
186
- wrap_if_else_while_for_fun_multi_line_in_curly ,
186
+ wrap_if_else_while_for_function_multi_line_in_curly ,
187
187
indent_by = indent_by
188
188
)
189
189
}
@@ -206,23 +206,23 @@ tidyverse_style <- function(scope = "tokens",
206
206
remove_space_after_excl = " '!'" ,
207
207
set_space_after_bang_bang = " '!'" ,
208
208
remove_space_around_dollar = " '$'" ,
209
- remove_space_after_fun_dec = " FUNCTION" ,
209
+ remove_space_after_function_declaration = " FUNCTION" ,
210
210
remove_space_around_colons = c(" ':'" , " NS_GET_INT" , " NS_GET" ),
211
211
start_comments_with_space = " COMMENT" ,
212
- remove_space_after_unary_pm_nested = c(" '+'" , " '-'" ),
212
+ remove_space_after_unary_plus_minus_nested = c(" '+'" , " '-'" ),
213
213
spacing_before_comments = " COMMENT" ,
214
214
set_space_in_curly = c(" '{'" , " '}'" )
215
215
),
216
216
indention = list (
217
217
# indent_braces = c("'('", "'['", "'{'", "')'", "']'", "'}'"),
218
- unindent_fun_dec = " FUNCTION" ,
218
+ unindent_function_declaration = " FUNCTION" ,
219
219
indent_eq_sub = c(" EQ_SUB" , " EQ_FORMALS" ), # TODO rename
220
- update_indention_ref_fun_dec = " FUNCTION"
220
+ update_indention_reference_function_declaration = " FUNCTION"
221
221
),
222
222
line_breaks = list (
223
223
set_line_break_before_curly_opening = " '{'" ,
224
224
remove_line_break_before_round_closing_after_curly = " '}'" ,
225
- remove_line_breaks_in_fun_dec = " FUNCTION" ,
225
+ remove_line_breaks_in_function_declaration = " FUNCTION" ,
226
226
set_line_break_around_curly_curly = " '{'" ,
227
227
style_line_break_around_curly = " '{'" ,
228
228
add_line_break_after_pipe = c(" SPECIAL-PIPE" , " PIPE" )
@@ -231,7 +231,7 @@ tidyverse_style <- function(scope = "tokens",
231
231
resolve_semicolon = " ';'" ,
232
232
add_brackets_in_pipe = c(" SPECIAL-PIPE" , " PIPE" ),
233
233
force_assignment_op = " EQ_ASSIGN" ,
234
- wrap_if_else_while_for_fun_multi_line_in_curly = c(
234
+ wrap_if_else_while_for_function_multi_line_in_curly = c(
235
235
" IF" , " WHILE" , " FOR" , " FUNCTION"
236
236
)
237
237
)
0 commit comments