Cyfrin / aderyn

Aderyn 🦜 Rust-based Solidity AST analyzer.
https://docs.cyfrin.io/
GNU General Public License v2.0
414 stars 62 forks source link

Rename `ConstantsInsteadOfLiterals` detector to better suit `//aderyn-ignore-(..)` #737

Closed TilakMaddy closed 1 month ago

TilakMaddy commented 2 months ago

Before:

// aderyn-ingore-next-line(constants-instead-of-literals)
uint256 y = 1034 + x * g;

Problem: It doesn't make sense to ignore the fact that constants are being used instead of literals

Other examples: we say aderyn-ignore-next-line(empty-block) .. we don't say aderyn-ignore-next-line(filled-block)

We state the problem in the detector's name

So I have renamed this

// aderyn-ingore-next-line(literal-instead-of-constant)
uint256 y = 1034 + x * g;

Now it reads, "ignore the fact that it's a literal instead of a constant"

`