Skip to content

Commit

Permalink
fix variable order printer by excluding immutables (#1184)
Browse files Browse the repository at this point in the history
  • Loading branch information
0xalpharush authored Apr 27, 2022
1 parent e94e02e commit 4d1bcc6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
install_requires=[
"prettytable>=0.7.2",
"pysha3>=1.0.2",
"crytic-compile>=0.2.3",
# "crytic-compile",
# "crytic-compile>=0.2.3",
"crytic-compile",
],
# dependency_links=["git+https://github.com/crytic/crytic-compile.git@master#egg=crytic-compile"],
dependency_links=["git+https://github.com/crytic/crytic-compile.git@master#egg=crytic-compile"],
license="AGPL-3.0",
long_description=long_description,
entry_points={
Expand Down
2 changes: 1 addition & 1 deletion slither/printers/summary/variable_order.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def output(self, _filename):
txt += f"\n{contract.name}:\n"
table = MyPrettyTable(["Name", "Type", "Slot", "Offset"])
for variable in contract.state_variables_ordered:
if not variable.is_constant:
if not variable.is_constant and not variable.is_immutable:
slot, offset = contract.compilation_unit.storage_layout_of(contract, variable)
table.add_row([variable.canonical_name, str(variable.type), slot, offset])

Expand Down

0 comments on commit 4d1bcc6

Please sign in to comment.