Description
Component
Forge
Describe the feature you would like
Currently a syntax like // forge-config: default.lint.exclude_lints = ["mixed-case-variable"]
defined on a function level would correctly ignore the lint rule violations defined here but is unwieldy and would override all exclusive lints defined on a global level rather than be additive.
// forge-config: default.lint.exclude_lints = ["mixed-case-variable"]
contract StdCheatsForkTest is Test {
MockUSDT public USDT;
MockUSDC public USDC;
}
There are cases like this where line level ignoring also makes sense:
note[screaming-snake-case-const]: constants should use SCREAMING_SNAKE_CASE
--> /forge-std/src/StdCheats.sol:656:25
|
656 | Vm private constant vm = Vm(address(uint160(uint256(keccak256("hevm cheat code")))));
We should have a syntax, preferably short like: // forge-lint-ignore: mixed-case-variable
to ignore and a // forge-lint: mixed-case-variable
to enable selectively.
Additionally we should optionally accept an array // forge-lint-ignore: [mixed-case-variable, foo-bar, bar-baz]
syntax and a // forge-lint: [mixed-case-variable, foo-bar, bar-baz]
to enable / ignore multiple.
Additional context
No response
Metadata
Metadata
Assignees
Type
Projects
Status