Ruby

Ruby

Made by DeepSource

Arguments to range literal are ambiguous RB-W1006

Bug risk
Major

Range literal should be enclosed in parentheses when the end of the range is at a line break, otherwise the intention of the code becomes ambigous.

Bad practice

1..
42

Recommended

(1..)
42

1..42

(1..42)

(1..
42)