keep-starknet-strange / cairo-lint

A collection of lints to catch common mistakes and improve your Cairo code.
21 stars 35 forks source link

Feat: add comparison_to_empty #130

Closed Benjtalkshow closed 1 month ago

Benjtalkshow commented 2 months ago

closes #74 @0xLucqs This is a draft PR

Implementation

Checks for comparing to an empty slice such as [], and suggests using .is_empty() where applicable.

Benjtalkshow commented 2 months ago

Alright @0xLucqs

Benjtalkshow commented 2 months ago

@0xLucqs i have made the requested changes

0xLucqs commented 2 months ago

fix clippy and don't forget to format

Benjtalkshow commented 2 months ago

fix clippy and don't forget to format

ok

0xLucqs commented 2 months ago

you need to add the tests to the test file similarly to how it's done with others

Benjtalkshow commented 2 months ago

@0xLucqs Please i just implemented the changes

0xLucqs commented 2 months ago

fix the tests, remove the useless added file and restore the cargo.lock plz

0xLucqs commented 2 months ago

and resolve conflicts

Benjtalkshow commented 2 months ago

fix the tests, remove the useless added file and restore the cargo.lock plz

alright