Ruby

Ruby

Made by DeepSource

Multiple comparison detected RB-LI1035

Bug risk
Major
Autofix

In math and Python, we can use x < y < z style comparison to compare multiple value. However, we can't use the comparison in Ruby. However, the comparison is not syntax error. This cop checks the bad usage of comparison operators.

Bad practice

x < y < z

Recommended

x < y && y < z