tests/testthat/indention_multiple/if_else_curly-out.R

{
  if (TRUE)
    3
  else
    4
}

{
  if (TRUE) {
    3
  } else
    4
}

{
  if (TRUE)
    3
  else {
    4
  }
}

{
  if (TRUE) {
    3
  } else {
    4
  }
}

# rather space than brace thing, but
foo <- function(x) {
  if (TRUE) {
    1
  } else {
    2
  }
}


if (TRUE) {
  3
} else  if (FALSE) {
  4
}

if (TRUE) {
  3
} else # comment
if (FALSE) {
  4
}
krlmlr/styler documentation built on April 8, 2024, 7:53 p.m.