You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Don't force line break removal after opening paren in function call if next token is a comment #171
changed the title [-]Don't force line break after opening paren in function call if next token in a comment[/-][+]Don't force line break removal after opening paren in function call if next token in a comment[/+]on Aug 30, 2017
changed the title [-]Don't force line break removal after opening paren in function call if next token in a comment[/-][+]Don't force line break removal after opening paren in function call if next token is a comment[/+]on Aug 30, 2017
I tried the package today. Is this issue the same as the following example? (The issue being that moving a comment from its own line to trailing is not a good change.)
lines<-"model <- lm( # this is the formula y ~ x, data = data.frame(x = rnorm(10), y = rnorm(10)))"
cat(lines)
#> model <- lm(#> # this is the formula#> y ~ x,#> data = data.frame(x = rnorm(10), y = rnorm(10))#> )
cat(paste0(styler::style_text(lines), collapse="\n"))
#> model <- lm( # this is the formula#> y ~ x,#> data = data.frame(x = rnorm(10), y = rnorm(10))#> )
Activity
krlmlr commentedon Aug 30, 2017
But this looks fine to me,
commentseems to be an argument tolist()also in the original code. What have I missed?[-]Don't force line break after opening paren in function call if next token in a comment[/-][+]Don't force line break removal after opening paren in function call if next token in a comment[/+][-]Don't force line break removal after opening paren in function call if next token in a comment[/-][+]Don't force line break removal after opening paren in function call if next token is a comment[/+]lorenzwalthert commentedon Aug 30, 2017
Just updated the example and title...
tjmahr commentedon Sep 5, 2017
I tried the package today. Is this issue the same as the following example? (The issue being that moving a comment from its own line to trailing is not a good change.)
lorenzwalthert commentedon Sep 5, 2017
Right. I think that's exactly this case. Thanks @tjmahr. #172 just needs a few tweaks before merging. Afterwards, it should work. Try to finish asap.
lorenzwalthert commentedon Sep 8, 2017
@tjmahr Hope you've noticed that this issue is closed as #172 was merged into master.