Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Live Example #21

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/foundry-storage-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@ jobs:
uses: foundry-rs/foundry-toolchain@v1.2.0

- name: Check storage layout
uses: Rubilmax/foundry-storage-check@main
uses: Rubilmax/foundry-storage-check@feat/showcase
with:
contract: contracts/Example.sol:Example
6 changes: 3 additions & 3 deletions contracts/Example.sol
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
struct Struct {
bool a;
uint256 b;
uint16 c;
uint16 d;
uint64 c;

Check failure on line 8 in contracts/Example.sol

View workflow job for this annotation

GitHub Actions / check_storage_layout

Variable type diff

variable "(Example.Struct structOf[0]).c" was of type "uint16" but is now "uint64" (storage slot 0x178c34144aa4f22f9dcdc9a6606881972cf65c835163e066ef62f7c270683765, byte #0)

Check failure on line 8 in contracts/Example.sol

View workflow job for this annotation

GitHub Actions / check_storage_layout

Variable diff

variable "(Example.Struct structOf[0]).d" of type "uint16" was replaced by variable "(Example.Struct structOf[0]).c" of type "uint64" (storage slot 0x178c34144aa4f22f9dcdc9a6606881972cf65c835163e066ef62f7c270683765, byte #2)

Check failure on line 8 in contracts/Example.sol

View workflow job for this annotation

GitHub Actions / check_storage_layout

Variable diff

variable "(Example.Struct structOf[0]).e" of type "address" was replaced by variable "(Example.Struct structOf[0]).c" of type "uint64" (storage slot 0x178c34144aa4f22f9dcdc9a6606881972cf65c835163e066ef62f7c270683765, byte #4)
uint64 d;

Check failure on line 9 in contracts/Example.sol

View workflow job for this annotation

GitHub Actions / check_storage_layout

Variable diff

variable "(Example.Struct structOf[0]).e" of type "address" was replaced by variable "(Example.Struct structOf[0]).d" of type "uint64" (storage slot 0x178c34144aa4f22f9dcdc9a6606881972cf65c835163e066ef62f7c270683765, byte #8)
address e;
}

Expand All @@ -15,7 +15,7 @@

uint256[10] __gap;

address _owner;
address owner;

Check warning on line 18 in contracts/Example.sol

View workflow job for this annotation

GitHub Actions / check_storage_layout

Label diff

variable "_owner" was renamed to "owner". Is it intentional? (storage slot 0x000000000000000000000000000000000000000000000000000000000000000b, byte #0)

mapping(address => Struct[]) structOf;
}
Loading