Omniscia Hot Cross Audit
Cross Code Style Findings
Cross Code Style Findings
CRO-01C: Unspecified Visibility Specifiers
Type | Severity | Location |
---|---|---|
Indeterminate Code | Informational | Cross.sol:L11 |
Description:
The CAP
variable of the Cross
token implementation does not have a visibility specifier defined that can lead to unexpected behaviour and discrepancies between compiler versions as one is automatically assigned by the compiler.
Example:
contracts/token/Cross.sol
11nt256 constant CAP = 100e24; // 100 million12
13nstructor() 14ERC20('Hot Cross', 'CROSS') 15ERC20Capped(CAP){}
Recommendation:
We advise a visibility specifier to be explicitly set to the variable to ensure no such discrepancies arise.
Alleviation:
The visibility specifier public
was explicitly set to the codebase alleviating this exhibit.