Skip to contents

Check that there is a space between right parenthesis and a body expression.

Usage

paren_body_linter()

See also

Examples

# will produce lints
lint(
  text = "function(x)x + 1",
  linters = paren_body_linter()
)
#> <text>:1:12: style: [paren_body_linter] Put a space between a right parenthesis and a body expression.
#> function(x)x + 1
#>            ^~~~~

# okay
lint(
  text = "function(x) x + 1",
  linters = paren_body_linter()
)
#>  No lints found.