Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
0xVolosnikov committed Aug 19, 2023
1 parent 3e3e71f commit ff776df
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions docs/rules/best-practises/explicit-types.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@ uint256 public variableName
uint public variableName
```

#### If explicit is selected

```solidity
uint256 public variableName = uint256(5)
```

### 👎 Examples of **incorrect** code for this rule

#### If explicit is selected
Expand All @@ -62,6 +68,12 @@ uint public variableName
uint256 public variableName
```

#### At any setting

```solidity
uint public variableName = uint256(5)
```

## Version
This rule was introduced in [Solhint 3.5.1](https://github.com/protofire/solhint/tree/v3.5.1)

Expand Down
2 changes: 1 addition & 1 deletion lib/rules/best-practises/explicit-types.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ const meta = {
code: 'uint256 public variableName',
},
{
description: 'If implicit is selected',
description: 'At any setting',
code: 'uint public variableName = uint256(5)',
},
],
Expand Down

0 comments on commit ff776df

Please sign in to comment.