macro_rules! register_lints {
( @declare_structs $( ($pass_id:ident, $pass_type:ident, ($($lint:expr),* $(,)?)) ),* $(,)? ) => { ... };
( @declare_consts $( ($pass_id:ident, $pass_type:ident, ($($lint:expr),* $(,)?)) ),* $(,)? ) => { ... };
( @declare_funcs $( ($pass_id:ident, $pass_type:ident, $lints:tt) ),* $(,)? ) => { ... };
(@early_impl $_pass_id:ident, late) => { ... };
(@early_impl $pass_id:ident, $other:ident) => { ... };
(@late_impl $_pass_id:ident, early) => { ... };
(@late_impl $pass_id:ident, $other:ident) => { ... };
(@early_create $_pass_id:ident, late) => { ... };
(@early_create $pass_id:ident, $_other:ident) => { ... };
(@late_create $_pass_id:ident, early) => { ... };
(@late_create $pass_id:ident, $_other:ident) => { ... };
( $($tokens:tt)* ) => { ... };
}Expand description
Registers Solidity linter passes that can have both early and late variants.
§Parameters
Each pass is declared with:
$pass_id: Identifier of the generated struct that will implement the pass trait(s).$pass_type: Eitherearly,late, orbothto indicate which traits to implement.$lints: A parenthesized, comma-separated list ofSolLintconstants.
§Outputs
- Structs for each linting pass
- Helper methods to create early and late passes with required lifetimes
const REGISTERED_LINTScontaining all registered lint objects