Useless logical and bitwise operations
Meaningless number operations are prohibited by WPS345.
But meaningless logical operations are not handled
```python
# not noticed
myvar = True or False
myvar = True and False
myvar = call() and False
myvar = call() and not True
myvar = call() or False
```
This may also be relevant for some bitwise operations
```python
# noticed by WPS345
myvar = 1 | False
myvar = 1 | 0
myvar = 1 & 0
# not noticed
myvar = 1 & True
myvar = 1 | True
myvar = 5 | 5
myvar = 452 & 452
```
Should we deal with this?
0 条评论