Skip to content

Commit

Permalink
Update src/ameba/rule/lint/logical_without_paren.cr
Browse files Browse the repository at this point in the history
Co-authored-by: Sijawusz Pur Rahnama <[email protected]>
  • Loading branch information
nobodywasishere and Sija authored Nov 25, 2024
1 parent 7e6d53f commit 5d56b04
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/ameba/rule/lint/logical_without_paren.cr
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ module Ameba::Rule::Lint
# YAML configuration example:
#
# ```
# Lint/LogicalWithoutParenthesis:
# Lint/RequireParentheses:
# Enabled: true
# ```
class LogicalWithoutParenthesis < Base
class RequireParentheses < Base
properties do
description "Disallows logical operators in method args without parenthesis"
description "Disallows method calls with no parentheses and a logical operator in the argument list"
end

MSG = "Logical operator in method args without parenthesis is not allowed"
MSG = "Use parentheses in the method call to avoid confusion about precedence"

ALLOWED_CALL_NAMES = %w{[]? []}

Expand Down

0 comments on commit 5d56b04

Please sign in to comment.