spaces_left_parentheses_linter: Spaces before parentheses linter

View source: R/spaces_left_parentheses_linter.R

spaces_left_parentheses_linterR Documentation

Spaces before parentheses linter

Description

Check that all left parentheses have a space before them unless they are in a function call.

Usage

spaces_left_parentheses_linter()

Tags

default, readability, style

See Also

Examples

# will produce lints
lint(
  text = "if(TRUE) x else y",
  linters = spaces_left_parentheses_linter()
)

# okay
lint(
  text = "if (TRUE) x else y",
  linters = spaces_left_parentheses_linter()
)


lintr documentation built on Nov. 7, 2023, 5:07 p.m.