Solhint

Solhint

Community Analyzer

Forbid or enforce explicit types (like uint256) that have an alias (like uint) SOLHINT-W1003

Anti-pattern
Minor

Forbid or enforce explicit types (like uint256) that have an alias (like uint).

Bad Practice

  1. If explicit is selected
uint public variableName
  1. If implicit is selected
uint256 public variableName
  1. At any setting
uint public variableName = uint256(5)

Recommended

  1. If explicit is selected
uint256 public variableName
  1. If implicit is selected
uint public variableName
  1. If explicit is selected
uint256 public variableName = uint256(5)

Learn more

explicit-types on Solhint's documentation.