Learn R Programming

lintr (version 3.1.2)

spaces_left_parentheses_linter: 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()

Arguments

Tags

default, readability, style

See Also

Examples

Run this code
# 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()
)

Run the code above in your browser using DataLab