erg-lang / erg

A statically typed language compatible with Python
http://erg-lang.org
Apache License 2.0
2.68k stars 55 forks source link

Linter: add "tautorogy" warning #502

Open mtshiba opened 6 months ago

mtshiba commented 6 months ago

Tracking issue: #501

We would like to warn code like:

assert 1 == 1
assert 1 <= 1
assert 1 >= 1
assert x + 1 == x + 1

Warn if LHS/RHS are clearly equal when comparing.